Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
1105 Внедрение механизмов обеспечения безопасности цепочки поставки программных проектов
Legacy
scanned-projects
helm
Commits
1832d525
Commit
1832d525
authored
6 years ago
by
Yuya Takeyama
Committed by
Matthew Fisher
6 years ago
Browse files
Options
Download
Patches
Plain Diff
Add --no-sudo option (#4649)
Signed-off-by:
Yuya Takeyama
<
sign.of.the.wolf.pentagram@gmail.com
>
parent
7b821dd5
release-2.17
dev-v2
release-2.12
release-2.13
release-2.14
release-2.15
release-2.16
v2.17.0
v2.17.0-rc.1
v2.16.12
v2.16.11
v2.16.10
v2.16.9
v2.16.8
v2.16.7
v2.16.6
v2.16.5
v2.16.4
v2.16.3
v2.16.2
v2.16.1
v2.16.0
v2.16.0-rc.2
v2.16.0-rc.1
v2.15.2
v2.15.1
v2.15.0
v2.15.0-rc.2
v2.15.0-rc.1
v2.14.3
v2.14.2
v2.14.1
v2.14.0
v2.14.0-rc.2
v2.14.0-rc.1
v2.13.1
v2.13.1-rc.1
v2.13.0
v2.13.0-rc.2
v2.13.0-rc.1
v2.12.3
v2.12.2
v2.12.1
v2.12.0
v2.12.0-rc.2
v2.12.0-rc.1
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
scripts/get
+6
-1
scripts/get
with
6 additions
and
1 deletion
+6
-1
scripts/get
+
6
−
1
View file @
1832d525
...
@@ -18,6 +18,7 @@
...
@@ -18,6 +18,7 @@
# the package manager for Go: https://github.com/Masterminds/glide.sh/blob/master/get
# the package manager for Go: https://github.com/Masterminds/glide.sh/blob/master/get
PROJECT_NAME
=
"helm"
PROJECT_NAME
=
"helm"
USE_SUDO
=
"true"
:
${
HELM_INSTALL_DIR
:
=
"/usr/local/bin"
}
:
${
HELM_INSTALL_DIR
:
=
"/usr/local/bin"
}
...
@@ -50,7 +51,7 @@ initOS() {
...
@@ -50,7 +51,7 @@ initOS() {
runAsRoot
()
{
runAsRoot
()
{
local
CMD
=
"
$*
"
local
CMD
=
"
$*
"
if
[
$EUID
-ne
0
]
;
then
if
[
$EUID
-ne
0
-a
$USE_SUDO
=
"true"
]
;
then
CMD
=
"sudo
$CMD
"
CMD
=
"sudo
$CMD
"
fi
fi
...
@@ -180,6 +181,7 @@ help () {
...
@@ -180,6 +181,7 @@ help () {
echo
-e
"
\t
[--help|-h ] ->> prints this help"
echo
-e
"
\t
[--help|-h ] ->> prints this help"
echo
-e
"
\t
[--version|-v <desired_version>] . When not defined it defaults to latest"
echo
-e
"
\t
[--version|-v <desired_version>] . When not defined it defaults to latest"
echo
-e
"
\t
e.g. --version v2.4.0 or -v latest"
echo
-e
"
\t
e.g. --version v2.4.0 or -v latest"
echo
-e
"
\t
[--no-sudo] ->> install without sudo"
}
}
# cleanup temporary files to avoid https://github.com/helm/helm/issues/2977
# cleanup temporary files to avoid https://github.com/helm/helm/issues/2977
...
@@ -209,6 +211,9 @@ while [[ $# -gt 0 ]]; do
...
@@ -209,6 +211,9 @@ while [[ $# -gt 0 ]]; do
exit
0
exit
0
fi
fi
;;
;;
'--no-sudo'
)
USE_SUDO
=
"false"
;;
'--help'
|
-h
)
'--help'
|
-h
)
help
help
exit
0
exit
0
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets