Skip to content

Commit

Permalink
Fix shellcheck issues
Browse files Browse the repository at this point in the history
  • Loading branch information
rake5k committed Sep 22, 2023
1 parent d19e226 commit 3e4ee8a
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions lib/apps/nixos-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ is_nvme_disk() {
}

get_partition() {
if is_nvme_disk; then
is_nvme="$(is_nvme_disk)"
local is_nvme
if "${is_nvme}"; then
echo "${DISK}p${1}"
else
echo "${DISK}${1}"
Expand Down Expand Up @@ -141,7 +143,9 @@ install() {

### Pull the trigger

if _read_boolean "Do you want to DELETE ALL PARTITIONS?" N; then
DO_PARTITION="$(_read_boolean "Do you want to DELETE ALL PARTITIONS?" N)"
readonly DO_PARTITION
if "${DO_PARTITION}"; then
partition
create_volumes
create_filesystems
Expand All @@ -155,7 +159,9 @@ if [[ ${LVM_PV_NUM_ACTIVE} -lt 1 ]]; then
decrypt_lvm
fi

if _read_boolean "Do you want to INSTALL NixOS now?" N; then
DO_INSTALL="$(_read_boolean "Do you want to INSTALL NixOS now?" N)"
readonly DO_INSTALL
if "${DO_INSTALL}"; then
install
fi

0 comments on commit 3e4ee8a

Please sign in to comment.