Safe line rebase

VerifiedSafe

Safely incorporates commits from the terminal station branch into the main working branch. It stashes any uncommitted work before rebasing, ensuring no data loss, and uses [skip line] markers in station commits to prevent retriggering the assembly line. Particularly useful when the line status shows pending station updates.

Sby Skills Guide Bot
DevelopmentIntermediate
1106/2/2026
Claude Code
#git-rebase#line-workflow#stash#branching

Recommended for

Our review

Rebases the watched branch onto the terminal station branch, stashing and restoring work in progress to avoid data loss.

Strengths

  • Preserves uncommitted changes via stashing
  • Avoids retriggering the line pipeline with [skip line]
  • Ensures no work is lost during rebase

Limitations

  • Requires the line.yaml configuration to be present
  • Will abort if conflicts arise (no auto-resolve)
  • Only works with the specific 'line' workflow conventions
When to use it

Use when the line statusline indicates pending changes on the terminal station branch that need to be integrated into your working branch.

When not to use it

Do not use if you want to cherry-pick only specific commits instead of rebasing the entire terminal station branch.

Security analysis

Safe
Quality score92/100

The skill uses git stash, rebase, and unstash operations locally without network access, no destructive commands like force push or reset, and includes safeguards for conflicts.

No concerns found

Examples

Pick up station changes
The line statusline shows the terminal station has commits I haven't picked up. Please rebase my watched branch onto the terminal station.
Synchronize with station
Check line.yaml, stash any pending changes, and rebase my current branch onto the latest terminal station, then restore my work.
Safe rebase from terminal
I have uncommitted work on my branch. Safely bring in the terminal station changes using rebase with stash.

/line-rebase

Safely pick up changes from the terminal station branch onto the watched branch.

When to use

Use this skill when the line statusline indicates there are commits ready on the terminal station branch that haven't been picked up on the main working branch.

Procedure

  1. Identify branches: Read line.yaml to determine the watched branch and the terminal (last) station.

  2. Check for changes: Verify the terminal station branch (line/stn/<terminal>) has commits ahead of the watched branch.

  3. Stash current work: If there are any uncommitted changes on the watched branch, stash them:

    git stash push -m "line-rebase: stashing WIP"
    
  4. Rebase from terminal station: Rebase the watched branch to include the terminal station's changes. All station commits contain [skip line] markers, so they will NOT retrigger the assembly line (SKL-2):

    git rebase line/stn/<terminal>
    
  5. Restore work in progress: If changes were stashed in step 3, restore them:

    git stash pop
    
  6. Verify: Confirm the watched branch now includes the station improvements and any WIP is restored.

Safety guarantees

  • No work is ever lost: WIP is always stashed before any branch operations
  • No retriggering: Station commits contain [skip line] which prevents line run from retriggering (RUN-9, SKL-2)
  • Fast and automatic: The entire operation is a stash, rebase, unstash sequence

Important

  • NEVER force-push or reset any branches
  • ALWAYS stash before rebase, even if the working tree appears clean
  • If the rebase has conflicts, abort and inform the user rather than auto-resolving
  • Verify the stash was applied successfully after the rebase
Related skills