Skip to content

Commit

Permalink
docs: refine history-limit docs, add warning (#50)
Browse files Browse the repository at this point in the history
  • Loading branch information
tranhl authored Dec 18, 2024
1 parent 379e52b commit 746f7a5
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,21 +162,22 @@ A pull request is considered to be **not** a part of a stack if:
### History Limit

In order to accurately visualize stacked changes, the action needs to fetch _all_ open
and closed pull requests. This can problematic for larger/older repositories that have
a large number of closed pull requests.
and closed pull requests. However, this can increase the runtime of the action for
larger/older repositories.

The action can be configured to fetch a limited number of closed pull requests. This is
customizable with the `history-limit` input:
If you're experiencing long runtimes, the `history-limit` input can be configured to
limit the total number of closed pull requests fetched by the action:

```yaml
- uses: git-town/action@v1
with:
history-limit: '500' # Only fetch the latest 500 closed pull requests
```

> [!NOTE]
> This only applies to closed pull requests. Open pull requests will be completely fetched
> regardless of the `history-limit`.
> [!WARNING]
> You may encounter inaccuracies in the visualization when customizing `history-limit` as
> open pull requests may refer to closed pull requests not fetched within the configured
> limits.

## Reference

Expand Down

0 comments on commit 746f7a5

Please sign in to comment.