forked from PharmTeX/class
-
Notifications
You must be signed in to change notification settings - Fork 0
/
executex
24 lines (19 loc) · 1.18 KB
/
executex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash
# PharmTeX Linux bash wrapper script, part of the PharmTeX platform.
# Copyright (C) 2021 Christian Hove Claussen ([email protected]).
# This program is free software: You can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program (see file named LICENSE). If not, see <https://www.gnu.org/licenses/>.
# Path to PharmTeX software installation
LDIR="$HOME/pharmtex"; export LDIR
# Path to PharmTeX files
PHARMTEXDIR="$LDIR/pharmtex"; export PHARMTEXDIR
# If no options set, prompt user
if [ "$1" == "" ]; then
read -p 'File to edit = ' CNAME
fi
# GUI mode
if [ "$CNAME" != "" ]; then
$PHARMTEXDIR/runlatex.sh "$CNAME" gui
exit
fi
# Run runlatex.bat with input options
$PHARMTEXDIR/runlatex.sh $*