Skip to content

Add 'hm lock update' and 'hm lock adopt' for lock-file-only pin updates - #1

Merged
aka-mj merged 1 commit into
masterfrom
mj/lock-update-adopt
Sep 2, 2026
Merged

aka-mj merged 1 commit into
masterfrom
mj/lock-update-adopt

Conversation

@aka-mj

@aka-mj aka-mj commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Two workflows previously required a full 'hm sync', which force-checks out the configured ref and rewrites the checkout as a side effect:

hm lock update pin each repo to the latest commit on its configured
branch (git ls-remote; checkouts untouched; --sync also
moves checkouts)
hm lock adopt pin each repo to its current local HEAD; refuses an
unpushed HEAD unless --force, since 'hm sync --locked'
could not reproduce it elsewhere

Both support -p/--project, -t/--tag, and --dry-run. Repositories pinned to a commit/tag in config are skipped by 'lock update'.

Also disable gpg signing in test-repo setup helpers so the suite does not hang on pinentry when the developer's global config sets commit.gpgSign.

Two workflows previously required a full 'hm sync', which force-checks out
the configured ref and rewrites the checkout as a side effect:

  hm lock update   pin each repo to the latest commit on its configured
                   branch (git ls-remote; checkouts untouched; --sync also
                   moves checkouts)
  hm lock adopt    pin each repo to its current local HEAD; refuses an
                   unpushed HEAD unless --force, since 'hm sync --locked'
                   could not reproduce it elsewhere

Both support -p/--project, -t/--tag, and --dry-run. Repositories pinned to
a commit/tag in config are skipped by 'lock update'.

Also disable gpg signing in test-repo setup helpers so the suite does not
hang on pinentry when the developer's global config sets commit.gpgSign.
@aka-mj
aka-mj merged commit ab9f281 into master Sep 2, 2026
1 check passed
@aka-mj
aka-mj deleted the mj/lock-update-adopt branch September 2, 2026 13:23
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.

1 participant