mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-23 06:26:15 +02:00
Merge pull request #4468 from Ma27/installer-no-progress-opt
scripts/install-nix-from-closure: only show progress if a terminal is used
This commit is contained in:
commit
29edbfe2d2
1 changed files with 7 additions and 1 deletions
|
@ -166,9 +166,15 @@ fi
|
||||||
mkdir -p $dest/store
|
mkdir -p $dest/store
|
||||||
|
|
||||||
printf "copying Nix to %s..." "${dest}/store" >&2
|
printf "copying Nix to %s..." "${dest}/store" >&2
|
||||||
|
# Insert a newline if no progress is shown.
|
||||||
|
if [ ! -t 0 ]; then
|
||||||
|
echo ""
|
||||||
|
fi
|
||||||
|
|
||||||
for i in $(cd "$self/store" >/dev/null && echo ./*); do
|
for i in $(cd "$self/store" >/dev/null && echo ./*); do
|
||||||
printf "." >&2
|
if [ -t 0 ]; then
|
||||||
|
printf "." >&2
|
||||||
|
fi
|
||||||
i_tmp="$dest/store/$i.$$"
|
i_tmp="$dest/store/$i.$$"
|
||||||
if [ -e "$i_tmp" ]; then
|
if [ -e "$i_tmp" ]; then
|
||||||
rm -rf "$i_tmp"
|
rm -rf "$i_tmp"
|
||||||
|
|
Loading…
Reference in a new issue