mirror of
https://github.com/KrumpetPirate/AAXtoMP3.git
synced 2024-11-18 03:08:57 +01:00
chg: use authcode file located in HOME dir.
Signed-off-by: Me <corbolais@gmail.com>
This commit is contained in:
parent
626bab226a
commit
1031e3ae1d
5
AAXtoMP3
5
AAXtoMP3
@ -5,6 +5,7 @@ set -o errexit -o noclobber -o nounset -o pipefail
|
|||||||
codec=libmp3lame
|
codec=libmp3lame
|
||||||
extension=mp3
|
extension=mp3
|
||||||
mode=chaptered
|
mode=chaptered
|
||||||
|
authcodeFile="${HOME}/.authcode";
|
||||||
GREP=$(grep --version | grep -q GNU && echo "grep" || echo "ggrep")
|
GREP=$(grep --version | grep -q GNU && echo "grep" || echo "ggrep")
|
||||||
|
|
||||||
if ! [[ $(type -P "$GREP") ]]; then
|
if ! [[ $(type -P "$GREP") ]]; then
|
||||||
@ -47,11 +48,11 @@ then
|
|||||||
shift
|
shift
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -f .authcode ]; then
|
if [ ! -f "$authcodeFile" ]; then
|
||||||
auth_code=$1
|
auth_code=$1
|
||||||
shift
|
shift
|
||||||
else
|
else
|
||||||
auth_code=`head -1 .authcode`
|
auth_code=`head -1 "$authcodeFile"`
|
||||||
fi
|
fi
|
||||||
|
|
||||||
debug() {
|
debug() {
|
||||||
|
Loading…
Reference in New Issue
Block a user