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
56a6bb68
You need to sign in or sign up before continuing.
Commit
56a6bb68
authored
Jun 12, 2019
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rpmbs: add -F option to run task after add
parent
bab63447
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
8 deletions
+10
-8
rpmbs
bin/rpmbs
+10
-8
No files found.
bin/rpmbs
View file @
56a6bb68
...
@@ -24,6 +24,7 @@ SIGN=
...
@@ -24,6 +24,7 @@ SIGN=
SIGNTAG
=
SIGNTAG
=
SETTAG
=
SETTAG
=
FORCE
=
FORCE
=
RUNTASK
=
UPLOADNOW
=
UPLOADNOW
=
CHECKONLY
=
CHECKONLY
=
TESTONLY
=
TESTONLY
=
...
@@ -63,6 +64,7 @@ phelp()
...
@@ -63,6 +64,7 @@ phelp()
echog
" -e sign and run gear test only task girar build"
echog
" -e sign and run gear test only task girar build"
echog
" -c only sign package(s) with checking"
echog
" -c only sign package(s) with checking"
echog
" -f force operation (overwrite tag)"
echog
" -f force operation (overwrite tag)"
echog
" -F force operation (overwrite tag) and run task after add"
echog
" -s sign package(s) (and move it to dir ETERDESTSRPM if defined)"
echog
" -s sign package(s) (and move it to dir ETERDESTSRPM if defined)"
echog
" -t set tag with sign"
echog
" -t set tag with sign"
echog
" -T set tag"
echog
" -T set tag"
...
@@ -72,7 +74,7 @@ phelp()
...
@@ -72,7 +74,7 @@ phelp()
# echog " -d - remove package(s) from SRPMS and Incoming"
# echog " -d - remove package(s) from SRPMS and Incoming"
}
}
while
getopts
:hfstTcudenop:a:Ab:z opt
;
do
while
getopts
:hf
F
stTcudenop:a:Ab:z opt
;
do
case
$opt
in
case
$opt
in
h
)
phelp
;
exit
0
;;
h
)
phelp
;
exit
0
;;
s
)
SIGN
=
1
;;
s
)
SIGN
=
1
;;
...
@@ -80,6 +82,7 @@ while getopts :hfstTcudenop:a:Ab:z opt; do
...
@@ -80,6 +82,7 @@ while getopts :hfstTcudenop:a:Ab:z opt; do
T
)
SETTAG
=
1
;;
T
)
SETTAG
=
1
;;
e
)
TESTONLY
=
"--test-only"
;
UPLOADNOW
=
1
;
SIGN
=
1
;;
e
)
TESTONLY
=
"--test-only"
;
UPLOADNOW
=
1
;
SIGN
=
1
;;
f
)
FORCE
=
"-f"
;;
f
)
FORCE
=
"-f"
;;
F
)
FORCE
=
"-f"
;
RUNTASK
=
1
;;
# FIXME: handle SIGN separately
# FIXME: handle SIGN separately
c
)
CHECKONLY
=
1
;
SIGN
=
1
;;
c
)
CHECKONLY
=
1
;
SIGN
=
1
;;
u
)
UPLOADNOW
=
1
;
SIGN
=
1
;;
u
)
UPLOADNOW
=
1
;
SIGN
=
1
;;
...
@@ -319,6 +322,7 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
...
@@ -319,6 +322,7 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
# TODO: add check for repo (as in rpmgp) and run ginit if needed
# TODO: add check for repo (as in rpmgp) and run ginit if needed
docmd gpush
$GIRARHOST
$FORCE
||
fatal
"gpush failed. It is possible you need run '
\$
ginit
$GIRARHOST
' to create remote repo."
docmd gpush
$GIRARHOST
$FORCE
||
fatal
"gpush failed. It is possible you need run '
\$
ginit
$GIRARHOST
' to create remote repo."
echo
echo
ATASKNUMBER
=
"
$TASKNUMBER
"
echo
"Run build
$PROJECTNAME
at
$GEARHOST
"
echo
"Run build
$PROJECTNAME
at
$GEARHOST
"
# FIXME: tee hangup during first call with ssh ControlMaster
# FIXME: tee hangup during first call with ssh ControlMaster
if
[
-n
"
$PREPARETASK
"
]
;
then
if
[
-n
"
$PREPARETASK
"
]
;
then
...
@@ -329,9 +333,9 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
...
@@ -329,9 +333,9 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
info
"
$PROJECTNAME
already present in the task
$TASKNUMBER
as subtask
$SUBTASK
, replacing"
info
"
$PROJECTNAME
already present in the task
$TASKNUMBER
as subtask
$SUBTASK
, replacing"
docmd ssh
$GEARHOST
task delsub
$TASKNUMBER
$SUBTASK
docmd ssh
$GEARHOST
task delsub
$TASKNUMBER
$SUBTASK
# add task subtask - before subtask! (use next number?)
# add task subtask - before subtask! (use next number?)
TASKNUMBER
=
"
$TASKNUMBER
$SUBTASK
"
A
TASKNUMBER
=
"
$TASKNUMBER
$SUBTASK
"
fi
fi
docmd ssh
$GEARHOST
task add
$TASKNUMBER
repo
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
docmd ssh
$GEARHOST
task add
$
A
TASKNUMBER
repo
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
else
else
docmd ssh
$GEARHOST
build
$TESTONLY
$(
usearg
-b
$BINARYREPO
sisyphus
)
$(
usearg
-p
$POCKET
)
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
docmd ssh
$GEARHOST
build
$TESTONLY
$(
usearg
-b
$BINARYREPO
sisyphus
)
$(
usearg
-p
$POCKET
)
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
fi
fi
...
@@ -346,14 +350,12 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
...
@@ -346,14 +350,12 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
done
done
if
[
-n
"
$TASKNUMBER
"
]
;
then
if
[
-n
"
$TASKNUMBER
"
]
;
then
# TODO: separate TASKNUMBER and SUBTASKNUMBER
showcmd
"GIT_ALT=
$GEARHOST
girar-show
$TASKNUMBER
@"
RTASKNUMBER
=
$(
echo
"
$TASKNUMBER
"
|
sed
-e
"s| .*||g"
)
GIT_ALT
=
$GEARHOST
girar-show
"
$TASKNUMBER
@"
showcmd
"GIT_ALT=
$GEARHOST
girar-show
$RTASKNUMBER
@"
GIT_ALT
=
$GEARHOST
girar-show
"
$RTASKNUMBER
@"
fi
fi
# if more then one spec, use common task
# if more then one spec, use common task
if
[
"
$PREPARETASK
"
=
"internal"
]
;
then
if
[
"
$PREPARETASK
"
=
"internal"
]
||
[
-n
"
$RUNTASK
"
]
;
then
docmd ssh
$GEARHOST
task run
$TESTONLY
$TASKNUMBER
docmd ssh
$GEARHOST
task run
$TESTONLY
$TASKNUMBER
fi
fi
...
...
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