mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-21 08:42:53 +02:00
Add support for the mv command in NS
This commit is contained in:
@@ -17,6 +17,20 @@ export class TextFile {
|
||||
*/
|
||||
text: string;
|
||||
|
||||
/**
|
||||
* The full file name.
|
||||
*/
|
||||
get filename(): string {
|
||||
return this.fn;
|
||||
}
|
||||
|
||||
/**
|
||||
* The full file name.
|
||||
*/
|
||||
set filename(value: string) {
|
||||
this.fn = value;
|
||||
}
|
||||
|
||||
constructor(fn = "", txt = "") {
|
||||
this.fn = (fn.endsWith(".txt") ? fn : `${fn}.txt`).replace(/\s+/g, "");
|
||||
this.text = txt;
|
||||
|
||||
Reference in New Issue
Block a user