diff options
| author | Tobias Geerinckx-Rice <me@tobias.gr> | 2022-10-16 02:00:00 +0200 |
|---|---|---|
| committer | Tobias Geerinckx-Rice <me@tobias.gr> | 2022-10-16 02:00:28 +0200 |
| commit | a326e3085da451c82ea461116ea1f59318f0f81d (patch) | |
| tree | f3fea54aeab4e0e87f9f865a6f5b96673d0cfee8 | |
| parent | 1e8e84b286acf147196ac95a515564324a0a9ae9 (diff) | |
guix-install.sh: Warn if we suspect dodgy automation.
This doesn't affect the installation (yet), but reserves the right to
default to safe values other than ‘y’ in future.
* etc/guix-install.sh (welcome): Warn if the ‘return’ wasn't.
| -rwxr-xr-x | etc/guix-install.sh | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/etc/guix-install.sh b/etc/guix-install.sh index 43dea3b605b..152accef776 100755 --- a/etc/guix-install.sh +++ b/etc/guix-install.sh | |||
| @@ -581,6 +581,7 @@ fi | |||
| 581 | 581 | ||
| 582 | welcome() | 582 | welcome() |
| 583 | { | 583 | { |
| 584 | local char | ||
| 584 | cat<<"EOF" | 585 | cat<<"EOF" |
| 585 | ░░░ ░░░ | 586 | ░░░ ░░░ |
| 586 | ░░▒▒░░░░░░░░░ ░░░░░░░░░▒▒░░ | 587 | ░░▒▒░░░░░░░░░ ░░░░░░░░░▒▒░░ |
| @@ -607,7 +608,13 @@ This script installs GNU Guix on your system | |||
| 607 | https://www.gnu.org/software/guix/ | 608 | https://www.gnu.org/software/guix/ |
| 608 | EOF | 609 | EOF |
| 609 | echo -n "Press return to continue..." | 610 | echo -n "Press return to continue..." |
| 610 | read -r | 611 | read -r char |
| 612 | if [ "$char" ]; then | ||
| 613 | echo | ||
| 614 | echo "...that ($char) was not a return!" | ||
| 615 | _msg "${WAR}Use newlines to automate installation, e.g.: yes '' | ${0##*/}" | ||
| 616 | _msg "${WAR}Any other method is unsupported and likely to break in future." | ||
| 617 | fi | ||
| 611 | } | 618 | } |
| 612 | 619 | ||
| 613 | main() | 620 | main() |
