From 29752840e59b642a38fae86f846670b10dee8c4e Mon Sep 17 00:00:00 2001 From: Michal Sojka Date: Tue, 25 Feb 2025 22:05:12 +0100 Subject: [PATCH 1/2] nix: Fix --pr-only Without this change, running "superflore-gen-nix --pr-only" fails with this error: !!!! Failed to file PR! !!!! reason: Cmd('/nix/store/cjw8ydwnifad0wdlkhpsyrdm18bcmg63-git-minimal-2.47.2/bin/git') failed due to: exit code(128) cmdline: /nix/store/cjw8ydwnifad0wdlkhpsyrdm18bcmg63-git-minimal-2.47.2/bin/git clone -v --branch=master -- https://github.com/./False False stderr: 'Cloning into 'False'... remote: Not Found fatal: repository 'https://github.com/./False/' not found ' Signed-off-by: Michal Sojka --- superflore/generators/nix/run.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/superflore/generators/nix/run.py b/superflore/generators/nix/run.py index 6fea4bb0..cd29cca9 100644 --- a/superflore/generators/nix/run.py +++ b/superflore/generators/nix/run.py @@ -23,7 +23,6 @@ regenerate_pkg_set from superflore.generators.nix.nix_ros_overlay import NixRosOverlay from superflore.parser import get_parser -from superflore.repo_instance import RepoInstance from superflore.TempfileManager import TempfileManager from superflore.utils import clean_up, get_distros_by_status from superflore.utils import err @@ -59,7 +58,7 @@ def main(): if not args.output_repository_path: parser.error('Invalid args! no repository specified') try: - prev_overlay = RepoInstance(args.output_repository_path, False) + prev_overlay = NixRosOverlay(args.output_repository_path, False) msg, title = load_pr() prev_overlay.pull_request(msg, title=title) clean_up() From 0b67677160875d754fdbe541f530c5e72ac1b957 Mon Sep 17 00:00:00 2001 From: Michal Sojka Date: Tue, 25 Feb 2025 22:49:04 +0100 Subject: [PATCH 2/2] nix: Make --pr-only obey --upstream-branch Signed-off-by: Michal Sojka --- superflore/generators/nix/run.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/superflore/generators/nix/run.py b/superflore/generators/nix/run.py index cd29cca9..cacd0a78 100644 --- a/superflore/generators/nix/run.py +++ b/superflore/generators/nix/run.py @@ -58,7 +58,11 @@ def main(): if not args.output_repository_path: parser.error('Invalid args! no repository specified') try: - prev_overlay = NixRosOverlay(args.output_repository_path, False) + prev_overlay = NixRosOverlay( + args.output_repository_path, + False, + from_branch=args.upstream_branch, + ) msg, title = load_pr() prev_overlay.pull_request(msg, title=title) clean_up()