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
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Seblu
installsystems
Commits
195ce71d
Commit
195ce71d
authored
13 years ago
by
Seblu
Browse files
Options
Downloads
Patches
Plain Diff
Fix bad caching selection and disabling
Thanks to Aurelien Dunand
parent
52b7900a
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
bin/is
+12
-12
12 additions, 12 deletions
bin/is
with
12 additions
and
12 deletions
bin/is
+
12
−
12
View file @
195ce71d
...
...
@@ -38,7 +38,7 @@ def load_repositories(args):
debug
(
"
Loaded repositories: %s
"
%
[
x
.
name
for
x
in
repos
])
return
repos
def
c_init_image
(
parser
,
args
,
config
):
def
c_init_image
(
parser
,
args
):
'''
Create a new source image
'''
...
...
@@ -47,7 +47,7 @@ def c_init_image(parser, args, config):
except
Exception
as
e
:
error
(
"
init image failed: %s.
"
%
e
)
def
c_init_repo
(
parser
,
args
,
config
):
def
c_init_repo
(
parser
,
args
):
'''
Create a empty repository
'''
...
...
@@ -60,7 +60,7 @@ def c_init_repo(parser, args, config):
except
Exception
as
e
:
raise
Exception
(
"
init repo failed: %s
"
%
e
)
def
c_build
(
parser
,
args
,
config
):
def
c_build
(
parser
,
args
):
'''
Build an image source
'''
...
...
@@ -78,7 +78,7 @@ def c_build(parser, args, config):
except
Exception
as
e
:
error
(
"
build failed: %s.
"
%
e
)
def
c_add
(
parser
,
args
,
config
):
def
c_add
(
parser
,
args
):
'''
Add an image package into a repository
'''
...
...
@@ -92,7 +92,7 @@ def c_add(parser, args, config):
except
Exception
as
e
:
raise
Exception
(
"
add failed: %s
"
%
e
)
def
c_del
(
parser
,
args
,
config
):
def
c_del
(
parser
,
args
):
'''
Remove an image package from a repository
'''
...
...
@@ -105,7 +105,7 @@ def c_del(parser, args, config):
except
Exception
as
e
:
raise
Exception
(
"
del failed: %s
"
%
e
)
def
c_install
(
parser
,
args
,
config
):
def
c_install
(
parser
,
args
):
'''
Install an image
'''
...
...
@@ -115,9 +115,9 @@ def c_install(parser, args, config):
elif
PackageImage
.
check_image_name
(
args
.
image
):
# remove cache is asked
if
args
.
no_cache
:
config
.
cache
=
None
args
.
cache
=
None
# init repo cache object
repoman
=
RepositoryManager
(
config
.
cache
,
timeout
=
args
.
timeout
)
repoman
=
RepositoryManager
(
args
.
cache
,
timeout
=
args
.
timeout
)
# load repositories
repos_config
=
load_repositories
(
args
)
# register repositories (order matter)
...
...
@@ -144,19 +144,19 @@ def c_install(parser, args, config):
dt
=
int
(
t1
-
t0
)
arrow
(
"
Install time: %s
"
%
datetime
.
timedelta
(
seconds
=
dt
))
def
c_search
(
parser
,
args
,
config
):
def
c_search
(
parser
,
args
):
'''
Search in repository
'''
raise
NotImplementedError
(
"
Not yet implemented
"
)
def
c_get
(
parser
,
args
,
config
):
def
c_get
(
parser
,
args
):
'''
Get a remove image in current directory
'''
raise
NotImplementedError
(
"
Not yet implemented
"
)
def
c_clean
(
parser
,
args
,
config
):
def
c_clean
(
parser
,
args
):
'''
Clean a repository
'''
...
...
@@ -259,7 +259,7 @@ try:
if
args
.
func
is
not
c_install
:
args
=
p_main
.
parse_args
(
namespace
=
args
)
# let's go
args
.
func
(
p_main
,
args
,
config
)
args
.
func
(
p_main
,
args
)
except
Exception
as
e
:
p_main
.
print_usage
()
error
(
e
)
...
...
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
register
or
sign in
to comment