Skip to content

Adding script options to help run current spec better#2

Open
Ataraxia009 wants to merge 3 commits intobitcoinknots:masterfrom
Ataraxia009:adding-more-options-for-versatility
Open

Adding script options to help run current spec better#2
Ataraxia009 wants to merge 3 commits intobitcoinknots:masterfrom
Ataraxia009:adding-more-options-for-versatility

Conversation

@Ataraxia009
Copy link
Copy Markdown

@Ataraxia009 Ataraxia009 commented Oct 16, 2025

Adding 2 more options:

bitcoin-core-master-branch: allow custom branch name for master, not everybody has it named master
ignore-missing-upstreams: Add option to ignore upstream checks for branches whose upstream has been deleted or removed
adding static committer and author email

@Ataraxia009 Ataraxia009 changed the title Adding more options for versatility Adding script options to help run current spec better Oct 16, 2025
Comment thread assemble-knots.pl Outdated
my $find_obsolete_merges;

GetOptions(
"bitcoin-core-master-branch=s" => \$bitcoin_core_master_branch,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Too project-specific naming

Comment thread assemble-knots.pl

# check if branch upstream_branch is accessible via remote
my $get_upstream_ec = gitmayfail("rev-parse", $upstreambranch);
if (not $get_upstream_ec) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should only be a condition if $ignore_missing_upstreams ?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i wrote it different, it seemed best to change this get_latest_upstream_branch function be stupid and try and return the latest upstreams if it can, instead of deciding what to do if the latest upstreams were not present.

then the caller can decide what to do if the upstreams are there are not.

just seems like better design

Comment thread assemble-knots.pl
$latest_upstream = $upstream;
$latest_upstream_time = $upstream_time;
}
die "Latest upstream is undefined!" unless $latest_upstream;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should keep this error

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we do, its just more downstream in the codepath

@Ataraxia009 Ataraxia009 force-pushed the adding-more-options-for-versatility branch from d9f73b4 to 0f22770 Compare November 10, 2025 19:34
Comment thread assemble-knots.pl Outdated

$ENV{GIT_COMMITTER_NAME} = "merge-script";
$ENV{GIT_AUTHOR_NAME} = $ENV{GIT_COMMITTER_NAME};
$ENV{GIT_COMMITTER_EMAIL} = "[email protected]";
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should probably set this in the spec file?

@Ataraxia009 Ataraxia009 force-pushed the adding-more-options-for-versatility branch from 0f22770 to 098ce0d Compare November 25, 2025 05:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants