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
18e3a83b
You need to sign in or sign up before continuing.
Commit
18e3a83b
authored
Oct 12, 2013
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rpmbs: add -A option for add to the current task
parent
735dc81a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
7 deletions
+9
-7
rpmbs
bin/rpmbs
+9
-7
No files found.
bin/rpmbs
View file @
18e3a83b
...
@@ -29,10 +29,11 @@ NOCHECK=
...
@@ -29,10 +29,11 @@ NOCHECK=
UPDATES
=
UPDATES
=
DELETENOW
=
DELETENOW
=
POCKET
=
POCKET
=
PREPARETASK
=
TASKNUMBER
=
TASKNUMBER
=
#############################
#############################
Usage
=
"Usage:
$name
[GIRAR] [-s|-t|-u|-a|-c] [-o -z -n -p --nodeps] [-k [TARGETDIR]] [spec or src.rpm]..."
Usage
=
"Usage:
$name
[GIRAR] [-s|-t|-u|-a|-
A|-
c] [-o -z -n -p --nodeps] [-k [TARGETDIR]] [spec or src.rpm]..."
function
mygetopts
()
function
mygetopts
()
{
{
name
=
${
0
##*/
}
name
=
${
0
##*/
}
...
@@ -45,7 +46,7 @@ phelp()
...
@@ -45,7 +46,7 @@ phelp()
echo
echo
echog
"Options:"
echog
"Options:"
echog
" -u sign and run gear build task after build"
echog
" -u sign and run gear build task after build"
echog
" -a TASK
sign package(s)/repo, push/upload it and add to (shared) task TASK"
echog
" -a TASK
| -A
sign package(s)/repo, push/upload it and add to (shared) task TASK"
echog
" -p POCKET build package in POCKET (supported on git.etersoft.ru only)"
echog
" -p POCKET build package in POCKET (supported on git.etersoft.ru only)"
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)"
echo
echo
...
@@ -63,7 +64,7 @@ phelp()
...
@@ -63,7 +64,7 @@ phelp()
# echog " -d - remove package(s) from SRPMS and Incoming"
# echog " -d - remove package(s) from SRPMS and Incoming"
}
}
while
getopts
:hfstcudnop:a:b:z opt
;
do
while
getopts
:hfstcudnop:a:
A
b:z opt
;
do
case
$opt
in
case
$opt
in
h
)
phelp
;
exit
0
;;
h
)
phelp
;
exit
0
;;
s
)
SIGN
=
1
;;
s
)
SIGN
=
1
;;
...
@@ -72,7 +73,8 @@ while getopts :hfstcudnop:a:b:z opt; do
...
@@ -72,7 +73,8 @@ while getopts :hfstcudnop:a:b:z opt; do
# 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
;;
a
)
UPLOADNOW
=
1
;
SIGN
=
1
;
TASKNUMBER
=
$OPTARG
;;
a
)
UPLOADNOW
=
1
;
SIGN
=
1
;
PREPARETASK
=
yes
;
TASKNUMBER
=
$OPTARG
;;
A
)
UPLOADNOW
=
1
;
SIGN
=
1
;
PREPARETASK
=
yes
;
TASKNUMBER
=
;;
# see functions/alt:set_binaryrepo() for BINARYREPONAME
# see functions/alt:set_binaryrepo() for BINARYREPONAME
b
)
BINARYREPONAME
=
$OPTARG
;;
b
)
BINARYREPONAME
=
$OPTARG
;;
n
)
NOCHECK
=
1
;
;;
n
)
NOCHECK
=
1
;
;;
...
@@ -236,7 +238,7 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
...
@@ -236,7 +238,7 @@ if [ -n "$UPLOADNOW" ] && is_gear $SPECDIR ; then
docmd
$ETERBUILDBIN
/gpush
$GIRARHOST
$FORCE
||
fatal
"gpush failed. Possibly you need to run '
\$
ginit
$GIRARHOST
' for create remote repo."
docmd
$ETERBUILDBIN
/gpush
$GIRARHOST
$FORCE
||
fatal
"gpush failed. Possibly you need to run '
\$
ginit
$GIRARHOST
' for create remote repo."
echo
echo
echo
"Run build
$PROJECTNAME
at
$GIRARHOST
"
echo
"Run build
$PROJECTNAME
at
$GIRARHOST
"
if
[
-n
"
$
TASKNUMBER
"
]
;
then
if
[
-n
"
$
PREPARETASK
"
]
;
then
docmd ssh
$GIRARHOST
task add
$TASKNUMBER
repo
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
docmd ssh
$GIRARHOST
task add
$TASKNUMBER
repo
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
else
else
docmd ssh
$GIRARHOST
build
-b
$BINARYREPO
$(
usearg
-p
$POCKET
)
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
docmd ssh
$GIRARHOST
build
-b
$BINARYREPO
$(
usearg
-p
$POCKET
)
$PROJECTNAME
$TAG
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
...
@@ -327,7 +329,7 @@ TASKLIST=""
...
@@ -327,7 +329,7 @@ TASKLIST=""
for
i
in
$LISTBUILT
;
do
for
i
in
$LISTBUILT
;
do
TASKLIST
=
"
$TASKLIST
srpm
$(
basename
$i
)
"
TASKLIST
=
"
$TASKLIST
srpm
$(
basename
$i
)
"
done
done
if
[
-n
"
$
TASKNUMBER
"
]
;
then
if
[
-n
"
$
PREPARETASK
"
]
;
then
echo
"Add
$TASKLIST
to task
$TASKNUMBER
"
echo
"Add
$TASKLIST
to task
$TASKNUMBER
"
docmd ssh
$GIRARHOST
task add
$TASKNUMBER
$TASKLIST
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
docmd ssh
$GIRARHOST
task add
$TASKNUMBER
$TASKLIST
2>&1 |
tee
$RPMDIR
/uploaded.log.tmp
else
else
...
@@ -344,7 +346,7 @@ for i in $LISTBUILT ; do
...
@@ -344,7 +346,7 @@ for i in $LISTBUILT ; do
date
>>
$LOGFILE
date
>>
$LOGFILE
echo
"uploaded"
>>
$LOGFILE
echo
"uploaded"
>>
$LOGFILE
TEXTADD
=
" run
$TASKNUMBER
build src.rpm"
TEXTADD
=
" run
$TASKNUMBER
build src.rpm"
[
-z
"
$
TASKNUMBER
"
]
||
TEXTADD
=
" add src.rpm to task
$TASKNUMBER
"
[
-z
"
$
PREPARETASK
"
]
||
TEXTADD
=
" add src.rpm to task
$TASKNUMBER
"
echo
"
$(
basename
$i
)
$TEXTADD
at
$GIRARHOST
(
$BINARYREPO
) at
`
date
"+%c"
`
"
>>
$RPMDIR
/uploaded.log
echo
"
$(
basename
$i
)
$TEXTADD
at
$GIRARHOST
(
$BINARYREPO
) at
`
date
"+%c"
`
"
>>
$RPMDIR
/uploaded.log
done
done
...
...
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