Skip to content

Commit 3bb4730

Browse files
committed
possibility of a global gameshell.sh, manpage for gameshell.sh
When calling a self extracting archive, it can be extracted in several places: - if we give a first argument to gameshell.sh which is a directory with rwx access right, the archive is extracted there - if the gameshell.sh (or save file) is inside a non writable directory, or if the file itself is non writable, the archive is extracted inside $HOME/.gameshell - otherwise, the archive is extracted next to the gameshell.sh file The save file is created in the same place where the archive was extracted. This is documented in a new gameshell.sh.1 manpage (only in English). This man page is available from within Gameshell (not very useful) but could be installed in standard man page directories if Gameshell is installed globally.
1 parent 90d7f14 commit 3bb4730

File tree

19 files changed

+1692
-129
lines changed

19 files changed

+1692
-129
lines changed

i18n/en.po

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,4 @@
11
# AUTOMATICALLY GENERATED -- DO NOT EDIT
2-
#, sh-format
3-
msgid "$GSH_ROOT/i18n/gsh-full-help/en.txt"
4-
msgstr "$GSH_ROOT/i18n/gsh-full-help/en.txt"
5-
6-
#, sh-format
7-
msgid "$GSH_ROOT/i18n/gsh-help/en.txt"
8-
msgstr "$GSH_ROOT/i18n/gsh-help/en.txt"
9-
102
#, sh-format
113
msgid "$GSH_ROOT/i18n/gameshell-init-msg-short/en.txt"
124
msgstr "$GSH_ROOT/i18n/gameshell-init-msg-short/en.txt"
@@ -19,6 +11,14 @@ msgstr "$GSH_ROOT/i18n/gameshell-init-msg/en.txt"
1911
msgid "$GSH_ROOT/i18n/gameshell-welcome/en.txt"
2012
msgstr "$GSH_ROOT/i18n/gameshell-welcome/en.txt"
2113

14+
#, sh-format
15+
msgid "$GSH_ROOT/i18n/gsh-full-help/en.txt"
16+
msgstr "$GSH_ROOT/i18n/gsh-full-help/en.txt"
17+
18+
#, sh-format
19+
msgid "$GSH_ROOT/i18n/gsh-help/en.txt"
20+
msgstr "$GSH_ROOT/i18n/gsh-help/en.txt"
21+
2222
#, sh-format
2323
msgid "$GSH_ROOT/i18n/start-full-help/en.txt"
2424
msgstr "$GSH_ROOT/i18n/start-full-help/en.txt"
@@ -169,6 +169,10 @@ msgstr "Error: you are not allowed to run this command."
169169
msgid "Error: you shouldn't run GameShell as root!"
170170
msgstr "Error: you shouldn't run GameShell as root!"
171171

172+
#, sh-format
173+
msgid "GameShell save file is at $SAVEFILE"
174+
msgstr "GameShell save file is at $SAVEFILE"
175+
172176
msgid "Is this information correct? [Y/n]"
173177
msgstr "Is this information correct? [Y/n]"
174178

i18n/fr.po

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,6 @@ msgstr "Content-Type: text/plain; charset=UTF-8\n"
33
"Content-Transfer-Encoding: 8bit\n"
44
"Plural-Forms: nplurals=2; plural=n>1;\n"
55

6-
#, sh-format
7-
msgid "$GSH_ROOT/i18n/gsh-full-help/en.txt"
8-
msgstr "$GSH_ROOT/i18n/gsh-full-help/fr.txt"
9-
10-
#, sh-format
11-
msgid "$GSH_ROOT/i18n/gsh-help/en.txt"
12-
msgstr "$GSH_ROOT/i18n/gsh-help/fr.txt"
13-
146
#, sh-format
157
msgid "$GSH_ROOT/i18n/gameshell-init-msg-short/en.txt"
168
msgstr "$GSH_ROOT/i18n/gameshell-init-msg-short/fr.txt"
@@ -23,6 +15,14 @@ msgstr "$GSH_ROOT/i18n/gameshell-init-msg/fr.txt"
2315
msgid "$GSH_ROOT/i18n/gameshell-welcome/en.txt"
2416
msgstr "$GSH_ROOT/i18n/gameshell-welcome/fr.txt"
2517

18+
#, sh-format
19+
msgid "$GSH_ROOT/i18n/gsh-full-help/en.txt"
20+
msgstr "$GSH_ROOT/i18n/gsh-full-help/fr.txt"
21+
22+
#, sh-format
23+
msgid "$GSH_ROOT/i18n/gsh-help/en.txt"
24+
msgstr "$GSH_ROOT/i18n/gsh-help/fr.txt"
25+
2626
#, sh-format
2727
msgid "$GSH_ROOT/i18n/start-full-help/en.txt"
2828
msgstr "$GSH_ROOT/i18n/start-full-help/fr.txt"
@@ -173,6 +173,10 @@ msgstr "Erreur : vous n'avez pas le droit d'exécuter cette commande."
173173
msgid "Error: you shouldn't run GameShell as root!"
174174
msgstr "Erreur: il ne faut pas lancer GameShell avec l'utilisateur root !"
175175

176+
#, sh-format
177+
msgid "GameShell save file is at $SAVEFILE"
178+
msgstr "Le fichier de sauvegarde GameShell se trouve à $SAVEFILE"
179+
176180
msgid "Is this information correct? [Y/n]"
177181
msgstr "Est-ce que ces informations sont correctes ? [O/n]"
178182

i18n/gsh-full-help/en.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ gsh auto
3636

3737
gsh goto [N]
3838
directly go to mission N
39-
(Note: no password necessary if N is a previous mission)
39+
(Note: no password necessary if N is an earlier mission)
4040

4141
gsh skip
4242
give up on the current mission and go to the next one
@@ -79,7 +79,7 @@ gsh hardreset
7979
reset the current mission by restarting the shell
8080

8181
gsh HELP
82-
this message
82+
show advanced usage status, with all existing Gameshell commands
8383

8484
gsh log [-v]
8585
show the log file of gsh commands

i18n/gsh-full-help/fr.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ gsh hardreset
8080
ré-initialise la mission en cours en redémarrant le shell
8181

8282
gsh HELP
83-
affiche ce message
83+
affiche un message d'aide complet, avec toutes les commandes Gameshell existantes
8484

8585
gsh log [-v]
8686
affiche le fichier de log des commandes gsh

i18n/it.po

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,6 @@ msgstr "Project-Id-Version: \n"
1313
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
1414
"X-Generator: Lokalize 22.04.1\n"
1515

16-
#, sh-format
17-
msgid "$GSH_ROOT/i18n/gsh-full-help/en.txt"
18-
msgstr "$GSH_ROOT/i18n/gsh-full-help/it.txt"
19-
20-
#, sh-format
21-
msgid "$GSH_ROOT/i18n/gsh-help/en.txt"
22-
msgstr "$GSH_ROOT/i18n/gsh-help/it.txt"
23-
2416
#, sh-format
2517
msgid "$GSH_ROOT/i18n/gameshell-init-msg-short/en.txt"
2618
msgstr "$GSH_ROOT/i18n/gameshell-init-msg-short/it.txt"
@@ -33,6 +25,14 @@ msgstr "$GSH_ROOT/i18n/gameshell-init-msg/it.txt"
3325
msgid "$GSH_ROOT/i18n/gameshell-welcome/en.txt"
3426
msgstr "$GSH_ROOT/i18n/gameshell-welcome/it.txt"
3527

28+
#, sh-format
29+
msgid "$GSH_ROOT/i18n/gsh-full-help/en.txt"
30+
msgstr "$GSH_ROOT/i18n/gsh-full-help/it.txt"
31+
32+
#, sh-format
33+
msgid "$GSH_ROOT/i18n/gsh-help/en.txt"
34+
msgstr "$GSH_ROOT/i18n/gsh-help/it.txt"
35+
3636
#, sh-format
3737
msgid "$GSH_ROOT/i18n/start-full-help/en.txt"
3838
msgstr "$GSH_ROOT/i18n/start-full-help/it.txt"
@@ -183,6 +183,10 @@ msgstr "Errore: non hai i permessi per eseguire questo comando."
183183
msgid "Error: you shouldn't run GameShell as root!"
184184
msgstr "Errore: non dovresti eseguire GameShell come root!"
185185

186+
#, sh-format
187+
msgid "GameShell save file is at $SAVEFILE"
188+
msgstr ""
189+
186190
msgid "Is this information correct? [Y/n]"
187191
msgstr "Questa informazione é corretta? [S/n]"
188192

i18n/source/gameshell/Makefile

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
MANPATH = ../../../man
2+
HELPPATH = ../..
3+
4+
LANGS = en
5+
MANPAGES = $(addsuffix .1, $(LANGS))
6+
7+
clean = sed -f ../clean.sed
8+
include_files = awk -f ../include_files.awk
9+
10+
all: $(MANPAGES)
11+
12+
install: all
13+
@mkdir -p $(MANPATH)/man1/
14+
for file in ??.1; do mkdir -p $(MANPATH)/$${file%.1}/man1/; cp "$$file" "$(MANPATH)/$${file%.1}/man1/gameshell.sh.1"; done
15+
mv $(MANPATH)/en/man1/* $(MANPATH)/man1/
16+
rmdir $(MANPATH)/en/man1/
17+
18+
%.txt: %/*.txt
19+
$(include_files) $*/man_gameshell.txt > $@
20+
21+
# NOTE: english man page should go to the default man/man1 directory
22+
en.1: en.txt
23+
a2x --doctype manpage --format manpage $<
24+
@mkdir -p $(MANPATH)/man1/
25+
mv gameshell.sh.1 $@
26+
27+
# NOTE: translated man pages should go to the man/LANGUAGE/man1 directory
28+
%.1: %.txt
29+
a2x --doctype manpage --format manpage $<
30+
@mkdir -p $(MANPATH)/$*/man1/
31+
mv gameshell.sh.1 $@
32+
33+
clean:
34+
rm -f *.1 *.html *.txt
35+
36+
.PHONY: clean all

0 commit comments

Comments
 (0)