rename .config to .zpkgconfig for XDG config collisions

This commit is contained in:
zawz 2021-04-07 10:44:58 +02:00
parent d0441d05af
commit fe46b00ba6
8 changed files with 9 additions and 9 deletions

2
.gitignore vendored
View file

@ -1,3 +1,3 @@
/.config /.zpkgconfig
/Zmakefile /Zmakefile
/zpkg /zpkg

View file

@ -14,4 +14,4 @@ minimal-deploy: minimal-build
scripts/server_deploy.sh scripts/server_deploy.sh
minimal-build: minimal-build:
lxsh -o zpkg -m --minimize-var --exclude-var "$(var_exclude)" --minimize-fct --remove-unused src/main.sh lxsh -o zpkg -m --minify-quotes --minify-var --exclude-var "$(var_exclude)" --minify-fct --remove-unused src/main.sh

View file

@ -55,7 +55,7 @@ You need to be able to SSH to the zpkg user, SSH keys are recommended
1. Clone this repository 1. Clone this repository
2. Write the desired config in `.config`, see `.config.example` 2. Write the desired config in `.zpkgconfig`, see `.zpkgconfig.example`
3. Run `make` 3. Run `make`

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
. "$(pwd)/.config" . "$(pwd)/.zpkgconfig"
[ -z "$TMPDIR" ] && TMPDIR=/tmp [ -z "$TMPDIR" ] && TMPDIR=/tmp
@ -19,7 +19,7 @@ random_string()
# add sources to server # add sources to server
ssh "$SSH_ADDRESS" mkdir -p "$PKG_PATH" || exit $? ssh "$SSH_ADDRESS" mkdir -p "$PKG_PATH" || exit $?
scp .config server_scripts/* "$SSH_ADDRESS":~/ || exit $? scp .zpkgconfig server_scripts/* "$SSH_ADDRESS":~/ || exit $?
## zpkg package ## zpkg package

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
. "$(pwd)/.config" . "$(pwd)/.zpkgconfig"
[ -z "$TMPDIR" ] && TMPDIR=/tmp [ -z "$TMPDIR" ] && TMPDIR=/tmp

View file

@ -1,13 +1,13 @@
#!/bin/sh #!/bin/sh
. "$(pwd)/.config" . "$(pwd)/.zpkgconfig"
# create install file # create install file
# header # header
echo '#!/bin/sh echo '#!/bin/sh
' > install.sh ' > install.sh
# add config # add config
cat .config >> install.sh cat .zpkgconfig >> install.sh
# body # body
echo ' echo '

View file

@ -36,7 +36,7 @@ package()
deploy_package() deploy_package()
{ {
echo "Deploying $(basename "$1"): $(du -sh "$1" | awk '{print $1}')iB" echo "Deploying $(basename "$1"): $(du -sh "$1" | awk '{print $1}')iB"
scp "$1" $SSH_ADDRESS:'$(grep "PKG_PATH=" .config | cut -d"=" -f2-)' scp "$1" $SSH_ADDRESS:'$(grep "PKG_PATH=" .zpkgconfig | cut -d"=" -f2-)'
} }
deploy_folder() deploy_folder()