Fix variable capitalization

This commit is contained in:
Dennis ten Hoove 2023-09-21 21:56:37 +02:00
parent 433324f1e6
commit 53a17a15a3
2 changed files with 7 additions and 7 deletions

View file

@ -21,12 +21,12 @@ Use the arkdep-build script to build your customlinux images.
sudo arkdep-build customlinux
# Or alternatively using a custom image name
sudo arkdep_OVERWRITE_RANDOM='customlinux_v1.0' arkdep-build customlinux
sudo ARKDEP_OVERWRITE_RANDOM='customlinux_v1.0' arkdep-build customlinux
```
Once done you can find compressed and uncompressed copies of your new image in the `target` directory.
arkdep will by default generate a psuedo-random hex string and use this as the name of your image. This behaviour can be overwritten by assigning a custom name to the `arkdep_OVERWRITE_RANDOM` environment variable.
arkdep will by default generate a psuedo-random hex string and use this as the name of your image. This behaviour can be overwritten by assigning a custom name to the `ARKDEP_OVERWRITE_RANDOM` environment variable.
## Repository

View file

@ -17,8 +17,8 @@ if [[ ! -n $1 || -n $2 ]]; then
are included by default.
Variables:
arkdep_NO_TAR Do not create a compressed tarball, only create the images
arkdep_OVERWRITE_RANDOM Define a custom image name
ARKDEP_NO_TAR Do not create a compressed tarball, only create the images
ARKDEP_OVERWRITE_RANDOM Define a custom image name
END
exit 0
fi
@ -62,8 +62,8 @@ cleanup_and_quit () {
# image names
gen_random_string () {
if [[ -v arkdep_OVERWRITE_RANDOM ]]; then
random=$arkdep_OVERWRITE_RANDOM
if [[ -v ARKDEP_OVERWRITE_RANDOM ]]; then
random=$ARKDEP_OVERWRITE_RANDOM
else
random=$(openssl rand -hex 100 | head -c 42)
fi
@ -185,7 +185,7 @@ if [[ $type == 'archlinux' ]]; then
btrfs send -f $output_target/$image_name/$image_name-etc.img $workdir/etc
btrfs send -f $output_target/$image_name/$image_name-var.img $workdir/var
if [[ ! -v arkdep_NO_TAR ]]; then
if [[ ! -v ARKDEP_NO_TAR ]]; then
printf "\e[1;34m-->\e[0m\e[1m Compressing images\e[0m\n"
tar -cv -I 'zstd -12 -T0 ' -f $output_target/$image_name.tar.zst -C $output_target/$image_name .
fi