From 1b99dcf6ef495e360f42140b2ee7cc14981afc1f Mon Sep 17 00:00:00 2001 From: nkulkarni Date: Wed, 22 Feb 2023 22:10:47 -0800 Subject: [PATCH 1/2] added unix time function --- config/commands.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/config/commands.js b/config/commands.js index 131a952a..9b4ac0a4 100644 --- a/config/commands.js +++ b/config/commands.js @@ -134,6 +134,11 @@ const commands = { term.stylePrint(_filesHere().join(" ")); }, + date: function() { + const date = new Date(); + term.stylePrint(date.toString()); + }, + // I am so, so sorry for this code. cd: function(args) { let dir = args[0] || "~"; From 39ad5ce9e809dbc2efc998cab069d6f07af91e49 Mon Sep 17 00:00:00 2001 From: nkulkarni Date: Wed, 22 Feb 2023 22:19:33 -0800 Subject: [PATCH 2/2] adding wget --- config/commands.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/config/commands.js b/config/commands.js index 9b4ac0a4..8ff3a9e8 100644 --- a/config/commands.js +++ b/config/commands.js @@ -400,6 +400,14 @@ const commands = { term.stylePrint(`Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource ${args[0]}.`); }, + wget: function(args) { + if (args[0] === undefined) { + term.stylePrint("wget: missing URL"); + return + } + term.stylePrint(`%wget% not installed. try: %curl% ${args[0]}`); + }, + ftp: function(args) { term.command(`curl ${args.join(" ")}`); },