Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
oh-my-zsh
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
github
oh-my-zsh
Commits
b79726b1
Unverified
Commit
b79726b1
authored
Sep 15, 2021
by
Marc Cornellà
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(update): silence `typeset` calls in `upgrade.sh` script (#10048)
Co-authored-by:
yyny
<
6576327+yyny@users.noreply.github.com
>
parent
4bd5d03e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
upgrade.sh
tools/upgrade.sh
+9
-2
No files found.
tools/upgrade.sh
View file @
b79726b1
#!/usr/bin/env zsh
#!/usr/bin/env zsh
# Protect against running with shells other than zsh
if
[
-z
"
$ZSH_VERSION
"
]
;
then
if
[
-z
"
$ZSH_VERSION
"
]
;
then
exec
zsh
"
$0
"
"
$@
"
exec
zsh
"
$0
"
"
$@
"
fi
fi
# Protect against unwanted sourcing
case
"
$ZSH_EVAL_CONTEXT
"
in
*
:file
)
echo
"error: this file should not be sourced"
&&
return
;;
esac
cd
"
$ZSH
"
cd
"
$ZSH
"
# Use colors, but only if connected to a terminal
# Use colors, but only if connected to a terminal
# and that terminal supports them.
# and that terminal supports them.
local
-a
RAINBOW
setopt typeset_silent
local
RED GREEN YELLOW BLUE BOLD DIM UNDER RESET
typeset
-a
RAINBOW
typeset
RED GREEN YELLOW BLUE BOLD DIM UNDER RESET
if
[
-t
1
]
;
then
if
[
-t
1
]
;
then
RAINBOW
=(
RAINBOW
=(
...
...
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