Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Oh My Zsh
Commits
b944fee6
Commit
b944fee6
authored
Jun 01, 2019
by
Marc Cornellà
Browse files
installer: ask user about changing the shell to zsh
parent
0824dcc9
Changes
1
Hide whitespace changes
Inline
Side-by-side
tools/install.sh
View file @
b944fee6
...
@@ -159,6 +159,15 @@ setup_shell() {
...
@@ -159,6 +159,15 @@ setup_shell() {
echo
"
${
BLUE
}
Time to change your default shell to zsh:
${
RESET
}
"
echo
"
${
BLUE
}
Time to change your default shell to zsh:
${
RESET
}
"
# Prompt for user choice on changing the default login shell
printf
"
${
YELLOW
}
Do you want to change your default shell to zsh? [Y/n]
${
RESET
}
"
read
opt
case
$opt
in
y
*
|
Y
*
|
""
)
echo
"Changing the shell..."
;;
n
*
|
N
*
)
echo
"Shell change skipped."
;
return
;;
*
)
echo
"Invalid choice. Shell change skipped."
;
return
;;
esac
# Test for the right location of the "shells" file
# Test for the right location of the "shells" file
if
[
-f
/etc/shells
]
;
then
if
[
-f
/etc/shells
]
;
then
shells_file
=
/etc/shells
shells_file
=
/etc/shells
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment