Skip to content

Commit 7687724

Browse files
committed
docs(ref): Document actions
Fixes gitext-rs#102
1 parent 5f22bbe commit 7687724

File tree

2 files changed

+42
-12
lines changed

2 files changed

+42
-12
lines changed

README.md

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -163,18 +163,6 @@ at a time within a stack. If you really need to, you can direct your reviewers
163163
to the commits within each PR to look at. However, you will see the CI run
164164
status of top commit for each PR dependency.
165165

166-
## When does `git-stack` consider a branch ready to be pushed?
167-
168-
A branch is ready if
169-
- It is not stacked on top of any other development branches (see "How do I stack my PRs in Github")
170-
- It has no WIP commits
171-
172-
We consider branches with [`fixup!`
173-
commits](https://git-scm.com/docs/git-commit#Documentation/git-commit.txt---fixupamendrewordltcommitgt)
174-
to be ready in case you are wanting reviewers to see some intermediate states.
175-
You can use a tool like [committed](https://github.com/crate-ci/committed) to
176-
prevent these from being merged.
177-
178166
## When is a commit considered WIP?
179167

180168
If a commit summary is only `WIP` or is prefixed by:

docs/reference.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,47 @@
11
# `git-stack` Reference
22

3+
## Actions
4+
5+
### `--pull`
6+
7+
Pulls your protected branches from the `stack.pull-remote` and then rebases
8+
your development branches on top of their relevant protected branches.
9+
10+
Unlike `--rebase`, this does not perform any "auto" operations.
11+
12+
Note:
13+
- This also performs a fetch of your `stack.push-remote` to take advantage of
14+
[`fetch.prune`](https://git-scm.com/docs/git-config#Documentation/git-config.txt-fetchprune)
15+
(`git config --global fetch.prune true`).
16+
17+
### `--rebase`
18+
19+
Rebase development branches on their relevant protected branches.
20+
21+
This performs "auto" operations, like
22+
- `stack.auto-fixup`: see `--fixup`
23+
24+
### `--fixup <action>`
25+
26+
Process [fixup!](https://git-scm.com/docs/git-config#Documentation/git-config.txt-fetchprune) commits according to the specified action.
27+
28+
Note:
29+
- This can be used to override `stack.auto-fixup` during a `--rebase`.
30+
31+
### `--push`
32+
33+
Push all "ready" development branches to your `stack.push-remote`.
34+
35+
A branch is ready if
36+
- It is not stacked on top of any other development branches (see ["How do I stack my PRs in Github"](../README.md#how-do-i-stack-my-prs-in-github))
37+
- It has no [WIP commits](../README.md#when-is-a-commit-considered-wip)
38+
39+
We consider branches with
40+
[`fixup!` commits](https://git-scm.com/docs/git-commit#Documentation/git-commit.txt---fixupamendrewordltcommitgt)
41+
to be ready in case you are wanting reviewers to see some intermediate states.
42+
You can use a tool like [committed](https://github.com/crate-ci/committed) to
43+
prevent these from being merged.
44+
345
## Configuration
446

547
### Sources

0 commit comments

Comments
 (0)