Add support for the mv command in NS

This commit is contained in:
Jeffrey A. Robinson
2022-01-12 09:53:54 -08:00
parent e9db656e13
commit bedea0ac73
6 changed files with 176 additions and 26 deletions
+14
View File
@@ -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;