Commit Graph
15 Commits
Author SHA1 Message Date
Gaëtan Lehmann a4135aaf8a Fix not subscriptable list type error with python 3.8
Signed-off-by: Gaëtan Lehmann <gaetan.lehmann@vates.tech>
2026-01-15 10:19:14 +01:00
Gaëtan Lehmann fa8bab3840 Use pure python code in place of os.system
os.system calls the user's shell, and is not directly checking for errors.
This should raise an error when cpio or rpm2cpio fail, or if they can't
be found.

Signed-off-by: Gaëtan Lehmann <gaetan.lehmann@vates.tech>
2025-08-25 17:59:10 +02:00
Yann Dirson 15ab08a8e3 import_srpm: don't attempt to fetch if we're not push/pulling
When we used `create_rpm_git_repo.py --local`, there may be no remote
to pull from yet.

Should indeed have been part of c2d89af47b.

Signed-off-by: Yann Dirson <yann.dirson@vates.tech>
2025-03-18 11:26:37 +01:00
Yann Dirson 04f862c875 import_srpm: remove broken no-commit behaviour, make -c the default
I was regularly losing time debugging this script exploding when just
forgetting to use `-c`.  Switching back to `master` after making changes
and NOT committing them has just NO WAY to ever work.

Signed-off-by: Yann Dirson <yann.dirson@vates.tech>
2025-03-07 16:31:14 +01:00
Yann Dirson 90a3b07043 import_srpm: use logging and trace git calls
Signed-off-by: Yann Dirson <yann.dirson@vates.tech>
2025-03-07 16:25:58 +01:00
Yann Dirson c2d89af47b import_srpm: do not pull if we do not push
Makes the script fully-local by default, providing a way to import on
local branches before we know if we want to published them.

Signed-off-by: Yann Dirson <yann.dirson@vates.tech>
2025-02-14 10:26:31 +01:00
Yann Dirson c056c92e1c import_srpm: add traces for main stages
That's enough to identify the context of a bug when --commit is not
used.

Signed-off-by: Yann Dirson <yann.dirson@vates.tech>
2025-02-06 14:46:01 +01:00
Samuel Verschelde 9dd8401594 import_srpm.py: don't import COPYING.CitrixCommercial
Signed-off-by: Samuel Verschelde <stormi-xcp@ylix.fr>
2022-08-31 17:00:29 +02:00
Samuel Verschelde fad1dbc8a2 Port scripts to python 3
The changes are trivial, at first sight.

Signed-off-by: Samuel Verschelde <stormi-xcp@ylix.fr>
2022-08-04 16:47:19 +02:00
Samuel Verschelde d514619b50 Add -s to git commit commands
- in scripts/create_rpm_git_repo.py
- in scripts/import_srpm.py

Signed-off-by: Samuel Verschelde <stormi-xcp@ylix.fr>
2022-01-25 17:19:10 +01:00
Samuel Verschelde 8770f3657c import_srpm.py: detect unexpected files in SOURCES directory 2020-07-07 17:42:46 +02:00
Samuel Verschelde a00e6c023c import_srpm.py: check for untracked files and tolerate empty SOURCES/ 2019-12-20 16:19:06 +01:00
Samuel Verschelde 84794a3962 Don't fail at importing an SRPM if nothing changed 2018-09-14 16:10:44 +02:00
Samuel Verschelde f95feea065 Do not try to create a git branch when it already exists 2018-08-02 13:36:08 +02:00
Samuel Verschelde 814d1a754b Add scripts used to create RPM source git repos and import SRPMs 2018-07-17 12:18:26 +02:00