sapling-stacked-pr-workflow
Skill0 starsChanged 39 days agoMITView on GitHub
Use when Sapling's `sl` needs an older stacked commit amended, a restack conflicts or orphans children, or GitHub stack PR diffs overlap unexpectedly
In this repository66 other files it gives its agents.
- AGENTS.mdAGENTS.md
- postgres-locking-joinsSkill
- ai-bug-patternsSkill
- compressed-ndjson-boundariesSkill
- http-resume-integritySkill
- linux-io-latency-triageSkill
- macos-disk-space-recoverySkill
- minimal-sufficient-evidenceSkill
- modularize-large-filesSkill
- patch-reproducer-validitySkill
- prompt-cache-boundariesSkill
- proton-drive-selective-backupSkill
- transactional-outbox-deliverySkill
- conventional-commitsSkill
- git-advanced-mergingSkill
- git-bisect-forensicsSkill
- git-data-recoverySkill
- git-hooksSkill
- git-rerereSkill
- git-reset-mechanicsSkill
- git-revisions-syntaxSkill
- git-rewriting-historySkill
- git-submodulesSkill
- git-worktreesSkill
- github-ssh-keysSkill
- npm-publish-ci-pitfallsSkill
- go-concurrency-patternsSkill
- go-data-idiomsSkill
- go-error-handlingSkill
- go-interfaces-embeddingSkill
- go-pprof-profilingSkill
- marketing-funnel-diagnosisSkill
- marketing-geo-experimentsSkill
- marketing-incrementalitySkill
- marketing-positioning-testsSkill
- python-descriptors-mroSkill
- python-logging-cookbookSkill
- python-scaling-regression-testsSkill
- python-unicode-gotchasSkill
- rust-compile-time-invariantsSkill
- rust-deterministic-concurrency-testsSkill
- rust-error-identity-boundariesSkill
- rust-regex-search-contractsSkill
- rust-runtime-bug-classesSkill
- rust-tokio-actor-deliverySkill
- rust-tokio-cancellation-safetySkill
- sales-discovery-qualificationSkill
- sales-mutual-action-plansSkill
- sales-pipeline-forecast-calibrationSkill
- sales-value-negotiationSkill
- ai-triage-evaluationSkill
- container-image-patchingSkill
- dependency-artifact-integritySkill
- dnssec-sentinel-diagnosticsSkill
- iam-policy-change-replaySkill
- rbvm-applicabilitySkill
- rbvm-asset-evidenceSkill
- rbvm-guarded-remediationSkill
- rbvm-priority-decisionsSkill
- rbvm-risk-exceptionsSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 12
Run sl and sl status. Confirm @, target, and pending files.
- Very specific: line 20
Use sl unamend on a draft leaf whose predecessor has matching parents.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Repair and Review Sapling Stacks
Sapling replaces amended commits; descendants restack or orphan on conflicts. Review edits in Smartlog (sl).
Edit a lower commit
- Run
slandsl status. Confirm@, target, and pending files. Unlike Git's index,sl amendincludes all pending changes by default. - At stack top, preview with
sl absorb --dry-run, then inspectsl absorbtargets before confirming. Accept only unambiguous chunks; unmatched changes stay pending. Absorbing can restack descendants and delete empty commits. - For a new file or ambiguous change, run
sl addremoveif needed, thensl amend --to REVwith the intended target. Orsl goto REVbefore amending. Confirm only intended files are pending. - Inspect
slafter edit. If children are orphaned, runsl restack; resolve conflicts thensl rebase --continue, orsl rebase --abortif unsafe. Verify graph and tests before publishing.
Recover a mistaken edit
sl undorestores the graph before the last graph operation;sl redoreverses that undo. It does not restore working-copy edits or retract remote publication.- Use
sl unamendon a draft leaf whose predecessor has matching parents; the delta becomes pending. Usesl uncommiton a mistaken draft leaf when no changes are pending. - Inspect an earlier version with
sl log -r "predecessors(REV)", replacingREVwith the target; inspect a candidate viasl showbeforesl unhide.
Choose the GitHub review shape
Use only already-authorized GitHub credentials. Sapling needs a PAT; docs recommend gh auth login --git-protocol https. If absent, ask the owner to configure credentials; never create or broaden them. Check sl ssl and default / default-push. Get owner authorization before remote changes: sl pr submit --stack, sl push --to remote/my-feature, or creating a GitHub PR. Stacked PRs include draft ancestors and all lower commits, so GitHub diffs overlap; use ReviewStack where supported. Branch-based PRs use one branch per review. sl push -f force-updates a branch; require explicit owner approval and follow team policy.
Pitfalls
- Amend changes commit IDs. Follow Smartlog, not stale hashes.
sl unhidealso reveals ancestors. Local undo/hide does not retract a pushed commit or close/update its PR.- Release 0.2.20260929 asks before
gotoof an obsolete commit or committing atop one;HGPLAIN=1retains old script behavior. Don't bypass the interactive prompt. - For
.github/workflowsPRs, defaultghscopes lackworkflow;sl pr submitmay create/update the PR, then abort on its archive-branch update. Check GitHub; stop and ask the owner to approvegh auth refresh -s workflowbefore expanding scope or retrying.
See SOURCES.md for official references, version scope, and validation limits.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

