Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Adam Mercer
Koji Packager
Commits
53d6abfd
Verified
Commit
53d6abfd
authored
May 09, 2019
by
Adam Mercer
Browse files
add --git option
this is for when the source is a git repository url
parent
df8690a2
Changes
1
Hide whitespace changes
Inline
Side-by-side
koji-packager
View file @
53d6abfd
...
...
@@ -48,16 +48,19 @@ def parse_options():
koji_options
.
add_argument
(
'--target'
,
default
=
__target__
,
help
=
'Koji tag to tag (%s)'
%
__target__
)
source_options
=
parser
.
add_argument_group
(
'Source Options'
)
source_options
.
add_argument
(
'--git'
,
action
=
'store_true'
,
help
=
'Source is from git'
)
source_options
.
add_argument
(
'source'
,
help
=
'Source to build with Koji'
)
# parse options
args
=
parser
.
parse_args
()
# check that source-rpm exists
source
=
pathlib
.
Path
(
args
.
source
)
if
not
source
.
is_file
():
print
(
'File %s does not exist.'
%
args
.
source
)
sys
.
exit
(
1
)
if
args
.
git
:
source
=
pathlib
.
Path
(
args
.
source
)
if
not
source
.
is_file
():
print
(
'File %s does not exist.'
%
args
.
source
)
sys
.
exit
(
1
)
return
args
...
...
Write
Preview
Supports
Markdown
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