Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
installsystems
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Seblu
installsystems
Commits
d1b6a114
Commit
d1b6a114
authored
May 16, 2012
by
Aurélien Dunand
Committed by
Sébastien Luttringer
May 16, 2012
Browse files
Options
Downloads
Patches
Plain Diff
Allow to build multiple images with build command
Signed-off-by:
Sébastien Luttringer
<
sebastien.luttringer@smartjog.com
>
parent
3d7b2db1
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
bin/is
+16
-12
16 additions, 12 deletions
bin/is
completion/bash/is
+1
-1
1 addition, 1 deletion
completion/bash/is
with
17 additions
and
13 deletions
bin/is
+
16
−
12
View file @
d1b6a114
...
...
@@ -105,10 +105,13 @@ def c_build(args):
'''
Build a source image in the current directory
'''
for
path
in
args
.
paths
:
arrow
(
"
Build %s
"
%
path
)
arrowlevel
(
1
)
# build start time
t0
=
time
.
time
()
# load source image
simg
=
SourceImage
(
args
.
path
)
simg
=
SourceImage
(
path
)
# do the job
simg
.
build
(
force
=
args
.
force
,
force_payload
=
args
.
payload
,
check
=
not
args
.
no_check
,
script
=
not
args
.
no_script
)
...
...
@@ -116,6 +119,7 @@ def c_build(args):
t1
=
time
.
time
()
dt
=
int
(
t1
-
t0
)
arrow
(
u
"
Build time: %s
"
%
datetime
.
timedelta
(
seconds
=
dt
))
arrowlevel
(
-
1
)
def
c_cat
(
args
):
'''
...
...
@@ -458,7 +462,7 @@ def arg_parser_init():
help
=
"
rebuild payloads if already exists
"
)
p
.
add_argument
(
"
-s
"
,
"
--no-script
"
,
action
=
"
store_true
"
,
help
=
"
doesn
'
t execute build script
"
)
p
.
add_argument
(
"
path
"
,
nargs
=
"
?
"
,
default
=
u
"
.
"
)
p
.
add_argument
(
"
path
s
"
,
nargs
=
"
*
"
,
default
=
u
"
.
"
)
p
.
set_defaults
(
func
=
c_build
)
# cat command parser
p
=
subparser
.
add_parser
(
"
cat
"
,
help
=
c_cat
.
__doc__
.
lower
())
...
...
This diff is collapsed.
Click to expand it.
completion/bash/is
+
1
−
1
View file @
d1b6a114
...
...
@@ -72,7 +72,7 @@ _is() {
build)
[[ "$cur" == -* ]] && _opt '-h --help -f --force -p --payload -c --no-check -s --no-script' && return 0
_count_args
(( args
=
= 2 )) && _filedir -d
(( args
>
= 2 )) && _filedir -d
;;
cat)
[[ "$cur" == -* ]] && _opt '-h --help' && return 0
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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
sign in
to comment