aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorMarkus Uhlin <markus@nifty-networks.net>2023-12-20 20:36:51 +0100
committerMarkus Uhlin <markus@nifty-networks.net>2023-12-20 20:36:51 +0100
commit5e9406502a1e1cc3e928de2a98d2e242acd0f910 (patch)
tree01fba1a26deb72d42347dc6f20242fcc83214c33 /scripts
parentc7021b2739411234a2ce13c87d6e0e57cae2dbe0 (diff)
i-data-admin.sh -- initial revision
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/i-data-admin.sh93
1 files changed, 93 insertions, 0 deletions
diff --git a/scripts/i-data-admin.sh b/scripts/i-data-admin.sh
new file mode 100755
index 0000000..4e01a6c
--- /dev/null
+++ b/scripts/i-data-admin.sh
@@ -0,0 +1,93 @@
+#!/bin/sh
+# SPDX-FileCopyrightText: 2023 Markus Uhlin <maxxe@rpblc.net>
+# SPDX-License-Identifier: ISC
+
+i_data_admin () {
+ local _src_prefix _dest _files
+
+ _src_prefix=${1}
+ _dest=${2}
+
+# adjrequests -> ../stats/player_data/a/adjudicate.messages
+# amotd -> ../messages/admotd*
+# bug -> ../stats/player_data/b/bug.messages
+# computerlist -> ../stats/player_data/c/computerlist.messages
+# events -> ../stats/player_data/e/event.messages
+# filtered -> ../stats/player_data/f/filter.messages
+# helpfiles -> ../stats/player_data/h/helpfiles.messages
+# multiaccounts -> ../stats/player_data/m/multiaccounts.messages
+# suggestion -> ../stats/player_data/s/suggestion.messages
+# vacation -> ../stats/player_data/v/vacation.messages
+ _files="
+accounts
+addaccounts
+addcomment
+addplayer
+adjudicate
+adjud_info
+admin
+admin_commands
+admin_hierarchy
+ahelp
+anews
+announce
+annunreg
+asetadmin
+asetblitz
+asetemail
+asethandle
+asetmaxplayer
+asetpasswd
+asetrealname
+asetstd
+asetv
+asetwild
+ban
+buglist
+canewsf
+canewsi
+chkgame
+chkip
+chkpl
+chksc
+chkts
+cmuzzle
+cnewsf
+cnewsi
+createanews
+filter
+finger
+lists
+muzzle
+nuke
+pose
+projects
+quota
+raisedead
+register
+remplayer
+rerank
+server_com
+showcomment
+shutdown
+summon
+"
+
+ echo "installing..."
+
+ for file in ${_files}; do
+ printf "%s -> %s: " "${_src_prefix}/${file}" "${_dest}/${file}"
+ if [ -r "${_src_prefix}/${file}" ]; then
+ install -m 0644 "${_src_prefix}/${file}" "${_dest}"
+ if [ $? -eq 0 ]; then
+ echo "ok"
+ else
+ echo "error"
+ fi
+ else
+ echo "not found"
+ fi
+ done
+}
+
+i_data_admin "${1}" "${2}"