Luigit
repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by admin

pi/agent/skillz/jj/jj-bookmark-move/SKILL.md

Raw
Rendered preview

name: jj-bookmark-move path: .jj disable-model-invocation: true description: "Move a Jujutsu target bookmark forward to the current change and push it. Use for direct linear integration without a merge commit."

Jj Bookmark Move

Use Jujutsu when jj root succeeds. Preserve unrelated work, use jj-native commands, and never allow a backwards bookmark move or force-push.

Procedure

  1. Inspect jj status; stop on unresolved conflicts.
  2. Resolve an explicit target bookmark first. Otherwise use trunk() or the first existing remote bookmark among trunk, main, and master; ask when none resolves. Use its tracked remote, or the sole configured remote; ask when ambiguous.
  3. Refuse when the current bookmark already is the target; synchronize it instead.
  4. Fetch the resolved remote.
  5. Verify the fetched target is an ancestor of the current change. Otherwise stop and require synchronization first.
  6. Verify moving the local target would not discard local-only target history.
  7. Require explicit authorization to advance the target.
  8. Run repository-required gates plus requested or obvious fast checks. Stop when a required check fails.
  9. Move the target bookmark to the current change without permitting a backwards move.
  10. Push the target bookmark normally. If rejected, fetch and repeat the ancestry and local-history checks once before one retry.
  11. Offer scoped abandonment of integrated changes or deletion of the source bookmark when safe; never clean up automatically.
  12. Report source change, target bookmark, remote, old and new target commits, checks, and push result.
---
name: jj-bookmark-move
path: .jj
disable-model-invocation: true
description: "Move a Jujutsu target bookmark forward to the current change and push it. Use for direct linear integration without a merge commit."
---

# Jj Bookmark Move

Use Jujutsu when `jj root` succeeds.
Preserve unrelated work, use jj-native commands, and never allow a backwards bookmark move or force-push.

## Procedure

1. Inspect `jj status`; stop on unresolved conflicts.
2. Resolve an explicit target bookmark first.
   Otherwise use `trunk()` or the first existing remote bookmark among `trunk`, `main`, and `master`; ask when none resolves.
   Use its tracked remote, or the sole configured remote; ask when ambiguous.
3. Refuse when the current bookmark already is the target; synchronize it instead.
4. Fetch the resolved remote.
5. Verify the fetched target is an ancestor of the current change.
   Otherwise stop and require synchronization first.
6. Verify moving the local target would not discard local-only target history.
7. Require explicit authorization to advance the target.
8. Run repository-required gates plus requested or obvious fast checks.
   Stop when a required check fails.
9. Move the target bookmark to the current change without permitting a backwards move.
10. Push the target bookmark normally.
    If rejected, fetch and repeat the ancestry and local-history checks once before one retry.
11. Offer scoped abandonment of integrated changes or deletion of the source bookmark when safe; never clean up automatically.
12. Report source change, target bookmark, remote, old and new target commits, checks, and push result.