Skip to content

Commit 0f32436

Browse files
committed
Add optional fetch_depth option for shallow clones
1 parent 866c166 commit 0f32436

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ Each example includes a complete workflow file that you can copy to your `.githu
8383
| `model` | Optional model name to use; passed directly to augment agent | No | e.g. `sonnet4`, from `auggie --list-models` |
8484
| `rules` | JSON array of rule file paths forwarded to augment agent as repeated `--rules` flags | No | `'[".augment/rules.md"]'` |
8585
| `mcp_configs` | JSON array of MCP config file paths forwarded as repeated `--mcp-config` flags | No | `'[".augment/mcp.json"]'` |
86+
| `fetch_depth` | Number of commits to fetch. Use `0` for full history (default), `1` for shallow clone, or any positive integer for specific depth | No | `1` (shallow), `50` (last 50 commits), `0` (full) |
8687

8788
## How It Works
8889

action.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ inputs:
3030
mcp_configs:
3131
description: "Optional JSON array of MCP config file paths to forward as --mcp-config flags to augmentcode/augment-agent."
3232
required: false
33+
fetch_depth:
34+
description: "Number of commits to fetch. Use '0' for full history (default), '1' for shallow clone (latest commit only), or any positive integer for a specific depth."
35+
required: false
36+
default: "0"
3337

3438
runs:
3539
using: "composite"
@@ -39,7 +43,7 @@ runs:
3943
with:
4044
token: ${{ inputs.github_token }}
4145
ref: refs/pull/${{ inputs.pull_number }}/head
42-
fetch-depth: 0
46+
fetch-depth: ${{ inputs.fetch_depth }}
4347

4448
- name: Prepare Custom Context
4549
id: custom_context

0 commit comments

Comments
 (0)