|
|
@@ -60,53 +60,11 @@ function pgsh(ev) {
|
|
|
'~ Welcome to Parsley Gardens! ~\n' +
|
|
|
'"He maketh me to lie down in green pa..."\n\n' +
|
|
|
'Type `<strong>help</strong>` for list of commands\n\n'
|
|
|
- this.tree = {
|
|
|
- 'bin': {},
|
|
|
- 'etc': {},
|
|
|
- 'home': {
|
|
|
- 'pgs': {
|
|
|
- 'git.txt':
|
|
|
- 'Code Repository at <a target="_blank"' +
|
|
|
- 'href="https://code.parsleygardens.net/explore/repos">' +
|
|
|
- 'code.parsleygardens.net</a>',
|
|
|
- 'magic.txt':
|
|
|
- 'Animation & Illustration at <a target="_blank"' +
|
|
|
- 'href="http://slightlymagic.com.au">' +
|
|
|
- 'slightlymagic.com.au</a>',
|
|
|
- 'about.md':
|
|
|
- '# Parsley Gardens Website\n\n' +
|
|
|
- '1. Made by Weiyi Lou ' + new Date().getFullYear() + '\n' +
|
|
|
- '2. Done for fun.\n' +
|
|
|
- '3. Not a real terminal.\n' +
|
|
|
- '4. But <a target="_blank" href="https://hyperterm.org/">this</a>' +
|
|
|
- ' totally is.'
|
|
|
- }
|
|
|
- },
|
|
|
- 'mnt': {},
|
|
|
- 'root': {
|
|
|
- 'bin': {
|
|
|
- 'destroy.sh':
|
|
|
- "#!/usr/bin/env bash\n" +
|
|
|
- "set -euo pipefail\n" +
|
|
|
- "IFS=$'\\n\\t'\n\n" +
|
|
|
- "rm -rf /"
|
|
|
- },
|
|
|
- 'everyday_lost_item_locations_global.sqlite': '',
|
|
|
- 'government-secrets.txt': ''
|
|
|
- },
|
|
|
- 'usr': {
|
|
|
- 'local': {
|
|
|
- 'bin': {
|
|
|
- 'nothing.txt': 'Really nothing'
|
|
|
- }
|
|
|
- }
|
|
|
- },
|
|
|
- 'var': {
|
|
|
- 'cache': {},
|
|
|
- 'log': {},
|
|
|
- 'run': {}
|
|
|
- }
|
|
|
- }
|
|
|
+ this.tree = pgfs
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Commands
|
|
|
+ */
|
|
|
this.commands = {
|
|
|
'about': { order: 1, help: 'Author Information' },
|
|
|
'cat': { order: 2, help: 'Con(cat)enate the contents of a file' },
|
|
|
@@ -123,10 +81,6 @@ function pgsh(ev) {
|
|
|
'su': { order: 2, help: 'Gain Phenomenal Cosmic Power' },
|
|
|
'version': { order: 1, help: 'Display shell information' }
|
|
|
}
|
|
|
-
|
|
|
- /**
|
|
|
- * Commands
|
|
|
- */
|
|
|
this.about = function(args) { self.cat(['/home/pgs/about.md']) }
|
|
|
this.magic = function(args) { self.cat(['/home/pgs/magic.txt']) }
|
|
|
this.cat = function(args) {
|
|
|
@@ -189,8 +143,8 @@ function pgsh(ev) {
|
|
|
}
|
|
|
}
|
|
|
show('\nAvailable commands:\n\n' +
|
|
|
- ' ' + main.sort().join(' ') + '\n\n' +
|
|
|
- ' ' + other.sort().join(' ') + '\n\n' +
|
|
|
+ '* ' + main.sort().join(' ') + '\n\n' +
|
|
|
+ '* ' + other.sort().join(' ') + '\n\n' +
|
|
|
'`help [command]` for more information.')
|
|
|
}
|
|
|
}
|