1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-09-20 17:26:15 +02:00
Commit Graph

3129 Commits

Author SHA1 Message Date
Marco Strigl
ff7b64d5eb
Merge pull request #727 from lethliel/version_in_osc_maintained
print verion in osc maintained if --version is given
2020-02-06 11:05:23 +01:00
lethliel
90dd172af0 print verion in osc maintained if -v is given
Determine the version of the package for maintained project
and print version or 'unknown' if version unknown.
2020-02-06 10:55:51 +01:00
lethliel
1ee7b638cc improve SSLError message
Improve the SSLError message if a version mismatch (TLSv1) is
detected and give the user a hint what is wrong.
(Basically the API does not supprt TLS <= 1.2 and the python
version does not support TLS >= 1.2)
2020-02-06 10:50:22 +01:00
Marcus Huewe
73d880e138 Fix bogus None check in core.vc_export_env
In case of an error, core.get_user_data returns an empty list.
None is never returned. Hence, only pop data from the returned list,
if it is non-empty.
2020-02-06 10:09:52 +01:00
Marcus Huewe
d22ca55975 Merge branch 'vertical' of https://github.com/adrianschroeter/osc
Add a "--vertical" option to "osc results <project>" to list the
packages vertically instead of horizontally.
2020-02-04 20:24:06 +01:00
Marcus Huewe
55dcfa72c6 Merge branch 'add_release_project_to_print_if_exists' of https://github.com/lethliel/osc
Print out the release project (if known) when creating a maintenance
request (just to be a bit more verbose).
2020-02-04 19:50:27 +01:00
Marcus Huewe
d94e457632 Merge branch 'fix_build_user_determination' of https://github.com/lethliel/osc
By default, pass --norootforbuild to the build script when running osc
shell/chroot (unless --userootforbuild is passed to osc).
2020-02-04 19:43:24 +01:00
8716dcc24a use signdummy for product builds
avoids build failure, but leads to unsigned media
2020-02-04 17:26:24 +01:00
37f19f7de9 fix counter handling for obsrepositories:/ in products
all entries had the same name, so repos got ignored.
2020-02-04 17:25:14 +01:00
2978b37fa7 - allow "osc r --vertical" for projects
dunno about others, but the default horizontal listing is not really
usable. This is at least true if you have more packages then
repostories.
2020-01-30 14:41:01 +01:00
lethliel
0b7b515f11 fix decoding in interactive request mode
In interactive review mode:

If a diff is issued and the request is accepted with 'a -m ok'
the tmpfile with the diff will be read. This tmpfile.read() call
is now decoded properly.
2020-01-24 09:23:24 +01:00
lethliel
82ca311eb3 print release_project on maintenancerequests
When creating maintenance requests print out the relese_project
if already known at this point.
2020-01-23 13:28:40 +01:00
lethliel
9849112278 append --norootforbuild as default
pass opts to run_build and check if norootforbuild
needs to be appended to cmd. (if opts.userootforbuild is not set)
2020-01-22 14:24:58 +01:00
Marcus Huewe
efbc60f147 Merge branch 'fix_deletereq_for_repo' of https://github.com/lethliel/osc
Support "osc deletereq <project> -r <REPO>" (previously, the -r option
could only be used if a <package> was specified as well).
2020-01-16 22:26:43 +01:00
lethliel
897c23c0ab Fix deletereq for repository
Do not require --all if --repository is given. There
are no packages touched when removing a repository for
a home project.
2020-01-16 09:01:43 +01:00
Marcus Huewe
a0514d299f Merge branch 'honor_rev_for_mr' of https://github.com/lethliel/osc
Do not ignore rev when creating a maintenance request (if the SR creation
fails).
2020-01-10 19:00:45 +01:00
Marco Strigl
3d2f1a4ffb
Merge pull request #718 from adrianschroeter/arch_zst
- support zstd arch linux files in local build
2020-01-10 14:06:56 +01:00
5f2721d8f6 - support zstd arch linux files in local build
Note: This requires a tar executable supporting zstd
2020-01-09 15:49:54 +01:00
lethliel
3a863a309c honor rev when creating maintenance incident
When creating a submit reqeust against a project that does not
accept SR anymore a maintenance request via create_maintenance_request
is generated. With this commit the orev will be honored and the
appropriate revision will be submitted.
2020-01-09 09:59:03 +01:00
Marcus Huewe
a6e49494c1 Merge branch 'drop_dead_code' of https://github.com/dcermak/osc
Get rid of unused core.dgst_from_string. Actually, this breaks the API
but that's IMHO ok (users of this, if at all, should be very rare)...
2020-01-08 18:18:55 +01:00
Quang Tran
86fcb7aecf
Fix typo in help message 2020-01-08 17:18:54 +01:00
136678ec21
Remove unused function dgst_from_string 2020-01-07 16:32:52 +01:00
lethliel
88abf11bd3 release 0.167.2 2020-01-07 11:29:52 +01:00
Marco Strigl
f0583c22c0
Merge pull request #713 from M0ses/fix_importsrcpkg
fix broken importsrcpkg for python3
2019-12-28 21:05:10 +01:00
lethliel
76793cc0ac fix regression in osc chroot
This fixes some regressions with osc chroot:

- osc chroot --wipe --root=/dir/ can now be called outside
  a working copy
- osc chroot --noinit --root=/dir/ can now be called outside
  a working copy and behaves like the old code (Just entering
  the chroot without any modifications)
- The confirmation of the deletion is implemented again and thus
  the --force option was implemented too.
2019-12-20 20:43:01 +01:00
Frank Schreiner
ae0b55de3b
fix broken importsrcpkg for python3
without this patch, `importsrcpkg` breaks with the following output:

```
  File "/usr/lib/python3.7/site-packages/osc/commandline.py", line 7868, in do_importsrcpkg
    createPackageDir(os.path.join(project.dir, pac), project)
  File "/usr/lib64/python3.7/posixpath.py", line 94, in join
    genericpath._check_arg_types('join', a, *p)
  File "/usr/lib64/python3.7/genericpath.py", line 151, in _check_arg_types
    raise TypeError("Can't mix strings and bytes in path components") from None
TypeError: Can't mix strings and bytes in path components
```

Fixes #712
2019-12-20 08:36:08 +01:00
lethliel
32ec356bad release 0.167.1 2019-12-10 13:39:55 +01:00
Marco Strigl
40abc51657
Merge pull request #698 from adrianschroeter/fix_api
fix Fetch api to become compatible again.
2019-12-10 11:43:59 +01:00
Marco Strigl
a5014eaa92
Merge pull request #704 from lethliel/remove_decoding_of_hdr_filename
remove decoding of hdr.filename
2019-12-10 11:38:16 +01:00
lethliel
67358c9746 remove decoding of hdr.filename
It is wrong in this case.
2019-12-10 11:24:17 +01:00
ef4e0411e9 fix Fetch api to become compatible again.
Broke in db795c8121 as reported by Marcus
2019-12-10 07:54:01 +01:00
lethliel
ade9baba52 fix lastbuildroot on builds not in WC
fix the lastbuildroot handling if the package is being build oustide of
a package directory and thus no .osc/ dir can be found.

We then just skip the store_write_last_buildroot and store_read_last_buildroot
calls.
2019-12-09 14:07:48 +01:00
Marcus Huewe
7621e79ddf Merge branch 'linux-platform-detection' of https://github.com/tomaskrizek/osc
Use the distro module (if available) for guessing the linux distribution.
In case of python < 3.8, use the platform.linux_distribution() fallback if
no distro module is available.
Rationale: platform.linux_distribution() was dropped in python3.8
2019-12-05 21:25:03 +01:00
db795c8121 support local building using RedHat rpm-md modules 2019-12-05 13:06:30 +01:00
lethliel
41158412f8 fix decoding in fetch_cpio 2019-12-05 13:02:24 +01:00
lethliel
d0de4c383d open 0.168.0 development 2019-12-05 10:46:17 +01:00
lethliel
2a2ea5c27d release 0.167.0 2019-12-05 10:44:46 +01:00
Tomas Krizek
eb894eff72
core: support distro module for platform detection
Python 3.8 no longer supports platform.linux_distribution().

Compatibility with Python 2.6+ is kept. The
platform.linux_distribution() function is available since 2.6:
https://docs.python.org/2.6/library/platform.html?platform.linux_distribution#platform.linux_distribution
2019-12-05 10:39:55 +01:00
Marco Strigl
8ec18e99a3
Merge pull request #694 from adrianschroeter/vm_build_fixes
VM build fixes
2019-12-05 10:26:40 +01:00
b08bd8a437 support building for kiwi products using obsrepositories:/ 2019-12-04 15:16:58 +01:00
b329b74816 build environement parameter caching
repository, architecture and vm_type from last build is automatically
reused if not specified otherwise.
2019-12-04 15:16:54 +01:00
47e346dde8 avoid source service run for "osc shell"
this also drops the warning line if service disabled. It seems not
to be important enough to me.
2019-12-04 14:50:15 +01:00
f4bdd3c876 avoid implicit --noinit if extra packages are specified 2019-12-04 14:50:15 +01:00
eb7aab1cf7 osc build --vm-disk-size= switch support 2019-12-04 14:50:15 +01:00
a628ea8cca read debug packages from server side project configuration
=> avoids unresolvable errors when distro is not providing the
    extra/debug package
2019-12-04 08:41:46 +01:00
Marco Strigl
8bebc13675
Merge pull request #678 from adrianschroeter/lastsucceeded
add --lastsucceeded option for logfile display
2019-12-04 08:36:30 +01:00
19168f4bb1
Merge pull request #690 from andreas-schwab/master
Doc fix
2019-12-03 17:30:24 +01:00
1f89b5a538 add --lastsucceeded option for logfile display
no single option since it is really a special usecase IMHO
jsc#OBS-40
2019-12-03 17:29:59 +01:00
33747d12a2 do not running local source service with "osc shell" 2019-12-02 14:33:17 +01:00
f480799522 Use --noinit and --offline on "osc shell" when environment exists 2019-12-02 14:23:41 +01:00
e5788030bf add --login-as-root alias of old "osc chroot".
is doing the same as --userootforbuild now
2019-12-02 14:23:41 +01:00
Andreas Schwab
5dfb80299c Doc fix 2019-12-02 13:12:59 +01:00
d46e93fb03 disable hostarch check for emulator builds entirely 2019-12-02 08:35:50 +01:00
2286f042ef improve help text for for build/shell/wipe 2019-11-28 10:21:05 +01:00
4bcb78e322 osc build --vm-type=qemu support for cross architecture builds 2019-11-28 10:07:36 +01:00
b78a0b3896 osc shell/chroot/wipe is now handled via build script (working for chroot and KVM only atm) 2019-11-28 10:07:11 +01:00
Andreas Schwab
7be5838e4e fix decoding for osc aggregatepac 2019-11-13 15:50:49 +01:00
lethliel
e16bd07e25 release 0.166.2 2019-11-13 13:02:57 +01:00
Marco Strigl
2bd921ee7c
Merge pull request #676 from lethliel/fix_http_debug_for_pub_key
fix output in http_debug mode for pubkey not found
2019-11-13 11:47:24 +01:00
lethliel
50891392ce fix output in http_debug mode for pubkey not found
Variable e is not known at the time of the call and
e.strerror is None nevertheless. So just ommit e.strerror.
2019-11-13 11:40:22 +01:00
lethliel
c32ec4bc1c appent opts.file to args not cmd_list
prepend to args instead to cmd_list. Otherwise the
changes file will be written into the given --file

osc vc --file=proposed.changes package.changes
2019-11-13 09:50:05 +01:00
Marco Strigl
f78057e2d5
Merge pull request #641 from mcepl/337_check_for_request_on_action_1
Make check_for_request_on_action on per default.
2019-11-05 16:03:59 +01:00
Marcus Huewe
8bb96776a8 Merge branch 'fix_decoding_linkpac' of https://github.com/lethliel/osc
Fix link_pac (meta_exists returns a list of bytes (if create_new is False)).
2019-11-04 15:11:57 +01:00
lethliel
02207d719c fix decoding for osc linkpac
in def link_pac dst_meta is a list of bytes-like objects.
so b''.join(dst_meta) is needed
2019-11-04 15:00:59 +01:00
Marcus Huewe
f9b1fa18ad Move passx handling into ObfuscatedConfigFileCredentialsManager
Minor cleanup for commit c5231d61dd
("fix credentials with passx entries").
2019-11-04 14:25:48 +01:00
Andreas Schwab
5227e357bc Don't enforce password reuse 2019-11-03 13:43:22 +01:00
lethliel
992255b0df release 0.166.1 2019-10-29 11:15:35 +01:00
lethliel
c5231d61dd fix credentials with passx entries
Existing passx enries resulted in a stacktrace because
the cp.get() call for the passx entries was missing.

Also added a delete_password function for ObfuscatedPasswordManager
to delete passx entries
2019-10-29 11:04:22 +01:00
lethliel
64a5969ca8 release 0.166.0 2019-10-24 11:48:35 +02:00
lethliel
2f02db1621 Merge branch 'master' of github.com:openSUSE/osc 2019-10-24 11:44:42 +02:00
Marco Strigl
aa50dca4eb
Merge pull request #650 from lethliel/fallback_if_keyring_not_present
catch configured keyring without module installed
2019-10-24 11:29:26 +02:00
lethliel
5fa1e73db6 catch configured keyring without module installed
If a python-keyring based backend is configured, but
python-keyring is not installed osc fails without giving
the user the opportunity to continue.

This introduces a new class method `create` for the AbstractCredentialsManager.
The CredentialsManagers for the backends that use a 3rd party software can
now check if the software is present in its own create method.
2019-10-24 11:21:23 +02:00
lethliel
af6d0bc652 osc ci improve error message on fail
The error message if the call of _commit is just:
"ERROR: service run failed"

One option why this can fail is that the user Editor in env('EDITOR')
is not present.

We check now if e.msg gives a hint about "not found file" and then
error out with a better error message
2019-10-23 14:12:03 +02:00
lethliel
d59141e3fe fix build with alternative prj and multibuild
building with alternative project (pac='_repository')
and multibuild did not work correctly, because the buildflavor
was not submitted to the src server.

With commit 2390823d649a3b0b6bf3b7bd07713c4426932bed in open-build-service
it is now possible to submit the build flavor like this: _repository:<flavor>

The obs commit also enables osc buildinfo --alternative-prject -M <flavor>
to show the correct buildinfo for the flavor.
2019-10-23 11:46:38 +02:00
Marco Strigl
6f34f2b8d8
Merge pull request #651 from lethliel/implement_incoming_option_for_rq
implement incoming option for osc rq
2019-10-22 13:15:17 +02:00
lethliel
b556095502 implement incoming option for osc rq
There is a config option 'include_request_from_project' which
can be set to 0 to exclude all requests originating from the
project in osc [rq|review] list.

To force this behaviour just once (without always editing oscrc
the '--incoming' option can be used.
2019-10-22 10:20:15 +02:00
Ludwig Nussel
e53d16f5d8 New browse command to quickly open web browser 2019-10-22 09:16:57 +02:00
Marcus Huewe
5611c55bde Merge branch 'fix_buildinfo_with_alternative_project' of https://github.com/lethliel/osc
Make "osc buildinfo --alternative-project <project> ..." consistent with
"osc build --alternative-project <project> ...". This change breaks some
invocations where a build_descr is omitted (but in this case, simply
use "osc buildinfo <project> <package> <repo> <arch>).
2019-10-21 16:16:55 +02:00
Marcus Huewe
3025dbf954 Merge branch 'support_appimage_yml' of https://github.com/adrianschroeter/osc
Support "appimage.yml" in parse_repoarchdescr.
2019-10-21 16:06:29 +02:00
lethliel
333028401e use _repository if alt prj is used
Use _repository as package name if alternative_project is used
2019-10-21 13:29:37 +02:00
e43d0641c6 find appimage.yml files as build description 2019-10-17 08:07:38 +02:00
lethliel
aaa51bcab1 improve help text for osc maintained
The help text does not indicate that only osc mbranch
really creates a branch.

osc maintained and osc sm are just aliases for osc mbranch --dryrun
2019-10-16 14:41:22 +02:00
ea5f8d40aa
Make check_for_request_on_action on per default.
Fixes #337
2019-10-10 18:02:20 +02:00
Marcus Huewe
95d49a0af6 Merge branch 'fix' of https://github.com/adrianschroeter/osc
Only a 404 implies a "meta_change" in link_pac and aggregate_pac.
2019-10-09 14:38:50 +02:00
e2c50fb8c1 be sure that destination is not existing before overwriting content
we used to crash on utf encoding errors, be sure not to replace meta
data in that case
2019-10-09 07:34:20 +02:00
Marcus Huewe
dc60cc2a09 Merge branch 'fix_#637_osc_vc_escape_chars' of https://github.com/lethliel/osc
Pass the filename to the vc script instead of passing its content via
the "-m" parameter. If "osc vc --file <fname>" is issued, it might be
possible that $EDITOR is still opened (if the "vc" script is too old),
which contradicts the --file option's help text. This "break" is acceptable
(just update osc in tandem with the vc script).
2019-09-27 22:35:25 +02:00
lethliel
edc2bde460 Transfer the name of the input file to vc
instead of the content and let vc do the rest.
This prevents calling echo -e and interpreting
escape characters.
2019-09-25 11:36:25 +02:00
Marco Strigl
99d305e969
Merge pull request #643 from lethliel/fix_quoted_output
unquote prj on osc co error message
2019-09-23 11:55:52 +02:00
40c480e9ef
Resurrect merge_cmd variable after it got removed in the past
In case diff3 returns something except 0 or 1, osc errors out because the
variable merge_cmd is not defined. It used to exist, but got removed in the
past and is reintroduced via this commit.
2019-09-20 21:56:35 +02:00
lethliel
e89c7dd12d unquote prj on osc co error message 2019-09-20 09:28:19 +02:00
Marco Strigl
e7e91709ef
Merge pull request #621 from lethliel/fix_#617_regression_in_deleterequest
make now() UTC aware for accept-in-hours
2019-09-18 16:57:56 +02:00
lethliel
ced4ac6506 append '+00:00' to now.isoformat() to satify api
just append '+00:00' so that the api calculates the correct accept time
based on UTC
2019-09-18 16:55:10 +02:00
Marcus Huewe
5756e90b90 Merge branch 'fix_decoding_in_osc_cat' of https://github.com/lethliel/osc
Do not perform any decoding in do_cat.
2019-09-18 16:36:00 +02:00
lethliel
6f674a6289 do not decode diff before passing it to run_pager
run_pager will take care of the bytes-like object and
will directly write it to sys.stdout.buffer.write() or
NamedTemporaryFile.
2019-09-18 11:26:16 +02:00
lethliel
d1d45f4618 fix decoding for osc cat
use sys.stdout.buffer.write() to print encoded data
correctly
2019-09-18 10:49:39 +02:00
Marco Strigl
1e4e7edad5
Merge pull request #446 from lethliel/add_error_for_issue_445
print error and exit if p.apiurl != -A <apiurl> using osc sr
2019-09-17 14:11:20 +02:00
lethliel
4b1e2343d8 fix TypeError with python3.7 configparser
configparser.py in python3.7 does not take None Type.
We override the _validate_value_types method in
OscConfigParser class to disable this check.
2019-09-17 13:35:30 +02:00
5f1109072f fix checkout of meta files
typo leaded to wrong parameter
2019-09-16 14:01:35 +02:00
Marco Strigl
035457cc26
Merge pull request #630 from lethliel/fix_decoding_on_lbl
decode data on osc lbl
2019-09-12 12:27:42 +02:00
lethliel
ee64437521 decode data on osc lbl 2019-09-12 10:41:26 +02:00