Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Synchronet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Main
Synchronet
Commits
d3270f8d
Commit
d3270f8d
authored
10 years ago
by
echicken
Browse files
Options
Downloads
Patches
Plain Diff
Comments, don't crap out on a command error.
parent
b8d1300d
No related branches found
No related tags found
Loading
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
exec/menushell.js
+32
-5
32 additions, 5 deletions
exec/menushell.js
with
32 additions
and
5 deletions
exec/menushell.js
+
32
−
5
View file @
d3270f8d
/* Menu Shell - uses menus created via 'menuedit.js'
Create your menus by running the following in your exec directory:
jsexec menuedit.js
Install the shell by first compiling the Baja launcher stub:
baja menushel.src
Then add the command shell to your configuration:
scfg
Command Shells
(Add a new entry)
Command Shell Name: Menu Shell
Command Shell Internal Code: MENUSHEL
This is not an example command shell. See classic_shell.js or lbshell.js
for examples of how to write your own shell, and consult Synchronet's JS
Object model documentation (http://synchro.net/docs/jsobjs.html) for help.
*/
load
(
"
sbbsdefs.js
"
);
load
(
"
sbbsdefs.js
"
);
load
(
"
menu-commands.js
"
);
load
(
"
menu-commands.js
"
);
...
@@ -47,11 +70,15 @@ var doMenu = function() {
...
@@ -47,11 +70,15 @@ var doMenu = function() {
if
(
typeof
command
.
menu
!=
"
undefined
"
)
{
if
(
typeof
command
.
menu
!=
"
undefined
"
)
{
menu
=
command
.
menu
;
menu
=
command
.
menu
;
}
else
{
}
else
{
var
path
=
command
.
command
.
split
(
"
.
"
);
try
{
// Let's not lose the entire session because of a bad command.
if
(
path
[
1
]
==
"
Externals
"
)
var
path
=
command
.
command
.
split
(
"
.
"
);
bbs
.
exec_xtrn
(
path
[
2
]);
if
(
path
[
1
]
==
"
Externals
"
)
else
bbs
.
exec_xtrn
(
path
[
2
]);
Commands
[
path
[
1
]][
path
[
2
]].
Action
();
else
Commands
[
path
[
1
]][
path
[
2
]].
Action
();
}
catch
(
err
)
{
log
(
LOG_ERR
,
err
);
}
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment