Skip to content

Commit 55b1e3c

Browse files
committed
clearer examples for init in docs
1 parent d37503f commit 55b1e3c

4 files changed

Lines changed: 7 additions & 9 deletions

File tree

README.md

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,10 @@ npx skills add github/gh-stack
2323
## Quick start
2424

2525
```sh
26-
# Start a new stack from the default branch
26+
# Start a new stack (creates and checks out the first branch)
2727
gh stack init
2828

29-
# Create the first branch and start working
30-
gh stack add auth-layer
31-
# ... make commits ...
29+
# ... make commits on the first branch ...
3230

3331
# Add another branch on top
3432
gh stack add api-endpoints
@@ -388,9 +386,8 @@ gh stack feedback "Support for reordering branches"
388386
## Typical workflow
389387

390388
```sh
391-
# 1. Start a stack
389+
# 1. Start a stack (creates and checks out the first branch)
392390
gh stack init
393-
gh stack add auth-middleware
394391

395392
# 2. Work on the first layer
396393
# ... write code, make commits ...

docs/src/content/docs/faq.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ You can create a stack using the `gh stack` CLI:
1919

2020
```sh
2121
gh stack init
22+
# ... make commits on the first branch ...
2223
gh stack add auth-layer
2324
# ... make commits ...
2425
gh stack add api-routes

docs/src/content/docs/guides/workflows.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,8 @@ This guide covers the most common workflows for day-to-day use of stacked PRs, f
1010
The basic flow: initialize a stack, add branches for each logical unit of work, commit, push, iterate on review feedback, and merge.
1111

1212
```sh
13-
# 1. Start a stack
13+
# 1. Start a stack (creates and checks out the first branch)
1414
gh stack init
15-
gh stack add auth-middleware
1615

1716
# 2. Work on the first layer
1817
# ... write code, make commits ...

docs/src/content/docs/index.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,9 @@ When you're ready to merge, you merge from the bottom up. Each PR can be merged
6060
# Install the CLI extension
6161
gh extension install github/gh-stack
6262

63-
# Create a stack, add branches, push PRs
63+
# Create a stack (creates and checks out the first branch)
6464
gh stack init
65+
# ... make commits ...
6566
gh stack add auth-layer
6667
# ... make commits ...
6768
gh stack add api-routes

0 commit comments

Comments
 (0)