source: scripts/usr/local/bin/7dtd.sh@ 90

Last change on this file since 90 was 23, checked in by alloc, 10 years ago

Version 6: Instance editing more userfriendly

  • Property svn:executable set to *
File size: 585 bytes
Line 
1#!/bin/bash
2
3. /usr/local/lib/7dtd/common.sh
4checkRootLoadConf
5
6if [ -z $1 ]; then
7 genericHelp
8else
9 CMD=$(camelcasePrep "$1")
10 shift
11
12 if [ "$CMD" = "Help" ]; then
13 if [ -z $1 ]; then
14 genericHelp
15 else
16 HELPCMD=$(camelcasePrep "$1")
17 if [ "$(type -t sdtdCommand${HELPCMD}Help)" = "function" ]; then
18 sdtdCommand${HELPCMD}Help
19 else
20 echo "Command \"$1\" does not exist!"
21 exit 1
22 fi
23 fi
24 else
25 if [ "$(type -t sdtdCommand${CMD})" = "function" ]; then
26 sdtdCommand${CMD} "$@"
27 else
28 echo "Command \"$CMD\" does not exist!"
29 exit 1
30 fi
31 fi
32fi
33
34exit 0
35
Note: See TracBrowser for help on using the repository browser.