Skip to content

Commit c28ae8b

Browse files
Martin Lopeschrispatthyeggman
authored
Reviewing previous workflow runs (#21489)
Co-authored-by: Chris Patterson <chrispat@github.com> Co-authored-by: Jacob Wallraff <thyeggman@github.com>
1 parent a32a8e3 commit c28ae8b

4 files changed

Lines changed: 73 additions & 46 deletions

File tree

48.6 KB
Loading

content/actions/managing-workflow-runs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ versions:
1414
ghae: '*'
1515
children:
1616
- /manually-running-a-workflow
17-
- /re-running-a-workflow
17+
- /re-running-workflows-and-jobs
1818
- /canceling-a-workflow
1919
- /approving-workflow-runs-from-public-forks
2020
- /reviewing-deployments

content/actions/managing-workflow-runs/re-running-a-workflow.md

Lines changed: 0 additions & 45 deletions
This file was deleted.
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
---
2+
title: Re-running workflows and jobs
3+
intro: You can re-run a workflow run up to 30 days after its initial run.
4+
product: '{% data reusables.gated-features.actions %}'
5+
permissions: People with write permissions to a repository can re-run workflows in the repository.
6+
miniTocMaxHeadingLevel: 3
7+
redirect_from:
8+
- /actions/managing-workflow-runs/re-running-a-workflow
9+
versions:
10+
fpt: '*'
11+
ghes: '*'
12+
ghae: '*'
13+
---
14+
15+
{% data reusables.actions.enterprise-beta %}
16+
{% data reusables.actions.enterprise-github-hosted-runners %}
17+
18+
## Re-running all the jobs in a workflow
19+
20+
Re-running a workflow uses the same `GITHUB_SHA` (commit SHA) and `GITHUB_REF` (Git ref) of the original event that triggered the workflow run. You can re-run a workflow for up to 30 days after the initial run.
21+
22+
{% include tool-switcher %}
23+
24+
{% webui %}
25+
26+
{% data reusables.repositories.navigate-to-repo %}
27+
{% data reusables.repositories.actions-tab %}
28+
{% data reusables.repositories.navigate-to-workflow %}
29+
{% data reusables.repositories.view-run %}
30+
{% ifversion fpt or ghes > 3.2 or ghae-issue-4721 %}
31+
1. In the upper-right corner of the workflow, use the **Re-run jobs** drop-down menu, and select **Re-run all jobs**
32+
![Rerun checks drop-down menu](/assets/images/help/repository/rerun-checks-drop-down.png)
33+
{% endif %}
34+
{% ifversion ghes < 3.3 or ghae %}
35+
1. In the upper-right corner of the workflow, use the **Re-run jobs** drop-down menu, and select **Re-run all jobs**.
36+
![Re-run checks drop-down menu](/assets/images/help/repository/rerun-checks-drop-down-updated.png)
37+
{% endif %}
38+
39+
{% endwebui %}
40+
41+
{% cli %}
42+
43+
{% data reusables.cli.cli-learn-more %}
44+
45+
To re-run a failed workflow run, use the `run rerun` subcommand. Replace `run-id` with the ID of the failed run that you want to re-run. If you don't specify a `run-id`, {% data variables.product.prodname_cli %} returns an interactive menu for you to choose a recent failed run.
46+
47+
```shell
48+
gh run rerun <em>run-id</em>
49+
```
50+
51+
To view the progress of the workflow run, use the `run watch` subcommand and select the run from the interactive list.
52+
53+
```shell
54+
gh run watch
55+
```
56+
57+
{% endcli %}
58+
59+
{% ifversion fpt or ghes > 3.2 or ghae-issue-4721 %}
60+
### Reviewing previous workflow runs
61+
62+
You can view the results from your previous attempts at running a workflow. You can also view previous workflow runs using the API. For more information, see ["Get a workflow run"](/rest/reference/actions#get-a-workflow-run).
63+
64+
{% data reusables.repositories.navigate-to-repo %}
65+
{% data reusables.repositories.actions-tab %}
66+
{% data reusables.repositories.navigate-to-workflow %}
67+
{% data reusables.repositories.view-run %}
68+
1. Any previous run attempts are shown in the left pane.
69+
![Rerun workflow](/assets/images/help/settings/actions-review-workflow-rerun.png)
70+
1. Click an entry to view its results.
71+
72+
{% endif %}

0 commit comments

Comments
 (0)