Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
etersoft-build-utils
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
korinf
etersoft-build-utils
Commits
797cad43
Commit
797cad43
authored
Aug 20, 2016
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
loginhsh: fix params with white spaces handling
parent
0da586dc
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
10 deletions
+9
-10
loginhsh
bin/loginhsh
+9
-10
No files found.
bin/loginhsh
View file @
797cad43
...
@@ -32,7 +32,7 @@ phelp()
...
@@ -32,7 +32,7 @@ phelp()
echog
" -b REPONAME binary repository name (4.1, p5, t6 and so on)"
echog
" -b REPONAME binary repository name (4.1, p5, t6 and so on)"
echog
" -c cleanup hasher"
echog
" -c cleanup hasher"
echog
" -q quiet mode (don't run anything)"
echog
" -q quiet mode (don't run anything)"
echog
" -r
run command"
echog
" -r
COMMAND
run command"
echog
" -o log in as root user"
echog
" -o log in as root user"
echog
" -v verbose"
echog
" -v verbose"
echog
" -X|-Y allow run X program (set DISPLAY and install xauth)"
echog
" -X|-Y allow run X program (set DISPLAY and install xauth)"
...
@@ -53,9 +53,9 @@ while getopts :chitodvqr:b:p:xXY opt; do
...
@@ -53,9 +53,9 @@ while getopts :chitodvqr:b:p:xXY opt; do
c
)
CLEANUP
=
1
;;
c
)
CLEANUP
=
1
;;
d
)
PRINTHASHERDIR
=
1
;;
d
)
PRINTHASHERDIR
=
1
;;
q
)
QUIETMODE
=
1
;;
q
)
QUIETMODE
=
1
;;
b
)
BINARYREPONAME
=
$OPTARG
;;
b
)
BINARYREPONAME
=
"
$OPTARG
"
;;
r
)
RUNCOMMAND
=
$OPTARG
;;
r
)
RUNCOMMAND
=
"
$OPTARG
"
;;
p
)
HASHERPOSTFIX
=
$OPTARG
;;
p
)
HASHERPOSTFIX
=
"
$OPTARG
"
;;
X
)
ALLOWX
=
-X
;;
X
)
ALLOWX
=
-X
;;
Y
)
ALLOWX
=
-Y
;;
Y
)
ALLOWX
=
-Y
;;
x
)
ALLOWX
=
-Y
;;
x
)
ALLOWX
=
-Y
;;
...
@@ -72,12 +72,12 @@ if [ $# -gt 0 ]; then
...
@@ -72,12 +72,12 @@ if [ $# -gt 0 ]; then
shift
$((
OPTIND
-
1
))
shift
$((
OPTIND
-
1
))
fi
fi
LIST
RPMARGS
=
$@
LIST
NAMES
=
"
$@
"
}
}
parse_cmd_pre
"
$@
"
--
#
parse_cmd_pre "$@" --
mygetopts
$LISTARGS
mygetopts
"
$@
"
# see functions/alt:set_binaryrepo() for BINARYREPONAME
# see functions/alt:set_binaryrepo() for BINARYREPONAME
set_binaryrepo
$MENV
set_binaryrepo
$MENV
...
@@ -125,13 +125,12 @@ if [ -n "$ALLOWX" ] ; then
...
@@ -125,13 +125,12 @@ if [ -n "$ALLOWX" ] ; then
fi
fi
if
[
-n
"
$QUIETMODE
"
]
;
then
if
[
-n
"
$QUIETMODE
"
]
;
then
docmd
$HSH
-install
$HASHERDIR
--wait-lock
$UTILPKG
$LIST
RPMARGS
$LIST
NAMES
||
fatal
"Error with install"
docmd
$HSH
-install
$HASHERDIR
--wait-lock
$UTILPKG
$LISTNAMES
||
fatal
"Error with install"
echog
"Exiting (quiet mode)..."
echog
"Exiting (quiet mode)..."
exit
exit
fi
fi
echog
"Prepare hasher in
$HASHERDIR
..."
echog
"Prepare hasher in
$HASHERDIR
..."
# there is package names in LISTRPMARGS
UTILPKG
=
"mc eepm"
UTILPKG
=
"mc eepm"
# GNOME program needs dbus-tools-gui
# GNOME program needs dbus-tools-gui
...
@@ -147,7 +146,7 @@ else
...
@@ -147,7 +146,7 @@ else
UTILPKG
=
"
$UTILPKG
etersoft-build-utils"
UTILPKG
=
"
$UTILPKG
etersoft-build-utils"
fi
fi
docmd
$HSH
-install
$HASHERDIR
--wait-lock
$UTILPKG
$LIST
RPMARGS
$LIST
NAMES
||
fatal
"Error with install"
docmd
$HSH
-install
$HASHERDIR
--wait-lock
$UTILPKG
$LISTNAMES
||
fatal
"Error with install"
if
[
-n
"
$RUNCOMMAND
"
]
;
then
if
[
-n
"
$RUNCOMMAND
"
]
;
then
docmd
$HSH
-run
$HASHERDIR
$SHELLHASHERARG
$ROOTER
--wait-lock
--
$RUNCOMMAND
docmd
$HSH
-run
$HASHERDIR
$SHELLHASHERARG
$ROOTER
--wait-lock
--
$RUNCOMMAND
...
...
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