Downloaded files may not have read permission for everybody.
This doesn't seem to be a problem since the user as well as
root should be able to read them anyhow. This is true unless
the directory where the cache resides is mounted over nfs
with root_squash.
Signed-off-by: Egbert Eich <eich@suse.de>
This duplicates the work of the source validator and is just annoying.
Suggested-by: Michal Vyskocil <mvyskocil@suse.cz>
Signed-off-by: Michal Marek <mmarek@suse.cz>
This helps to implement an efficient way to create source tarballs from Git repositories:
1. The cloned Git repository will be stored only once in a directory; all projects will use this repository (determined by the URL).
2. The bzip2 compressed tarball will be created via 'git archive $branch $filestoinclude --prefix=$name | bzip2 --best >$projdir/$name-$version'.
3. The version will be adapted automatically without the set_version service.
4. All branched/linked projects will be updated automatically (does not with current implementation).
5. Not to mention it saves space on source host(s).
Exchange individual return statements with a finally statement in the
big try/except statement in babysitter.py. If you return a different
value in the 'except' clause, it takes precedency over the 'finally'
clause (finally is executed before returning, naturally).
This fixes:
~> osc checkout
Traceback (most recent call last):
File "/usr/bin/osc", line 21, in <module>
r = babysitter.run(osccli)
File "/usr/lib/python2.7/site-packages/osc/babysitter.py", line 52, in run
return prg.main()
File "/usr/lib/python2.7/site-packages/osc/cmdln.py", line 310, in main
return self.cmd(args)
File "/usr/lib/python2.7/site-packages/osc/cmdln.py", line 333, in cmd
retval = self.onecmd(argv)
File "/usr/lib/python2.7/site-packages/osc/cmdln.py", line 449, in onecmd
return self._dispatch_cmd(handler, argv)
File "/usr/lib/python2.7/site-packages/osc/cmdln.py", line 1179, in _dispatch_cmd
return handler(argv[0], opts, *args)
File "/usr/lib/python2.7/site-packages/osc/commandline.py", line 3386, in do_checkout
m = re.match(r"obs://([^/]+)/(\S+)/([^/]+)/([A-Fa-f\d]+)\-(\S+)", args[0])
IndexError: tuple index out of range
Signed-off-by: Petr Uzel <petr.uzel@suse.cz>