Skip to content

Commit

Permalink
Reviewing previous workflow runs (github#21489)
Browse files Browse the repository at this point in the history
Co-authored-by: Chris Patterson <[email protected]>
Co-authored-by: Jacob Wallraff <[email protected]>
  • Loading branch information
3 people authored Oct 8, 2021
1 parent a32a8e3 commit c28ae8b
Show file tree
Hide file tree
Showing 4 changed files with 73 additions and 46 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion content/actions/managing-workflow-runs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ versions:
ghae: '*'
children:
- /manually-running-a-workflow
- /re-running-a-workflow
- /re-running-workflows-and-jobs
- /canceling-a-workflow
- /approving-workflow-runs-from-public-forks
- /reviewing-deployments
Expand Down
45 changes: 0 additions & 45 deletions content/actions/managing-workflow-runs/re-running-a-workflow.md

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
---
title: Re-running workflows and jobs
intro: You can re-run a workflow run up to 30 days after its initial run.
product: '{% data reusables.gated-features.actions %}'
permissions: People with write permissions to a repository can re-run workflows in the repository.
miniTocMaxHeadingLevel: 3
redirect_from:
- /actions/managing-workflow-runs/re-running-a-workflow
versions:
fpt: '*'
ghes: '*'
ghae: '*'
---

{% data reusables.actions.enterprise-beta %}
{% data reusables.actions.enterprise-github-hosted-runners %}

## Re-running all the jobs in a workflow

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.

{% include tool-switcher %}

{% webui %}

{% data reusables.repositories.navigate-to-repo %}
{% data reusables.repositories.actions-tab %}
{% data reusables.repositories.navigate-to-workflow %}
{% data reusables.repositories.view-run %}
{% ifversion fpt or ghes > 3.2 or ghae-issue-4721 %}
1. In the upper-right corner of the workflow, use the **Re-run jobs** drop-down menu, and select **Re-run all jobs**
![Rerun checks drop-down menu](/assets/images/help/repository/rerun-checks-drop-down.png)
{% endif %}
{% ifversion ghes < 3.3 or ghae %}
1. In the upper-right corner of the workflow, use the **Re-run jobs** drop-down menu, and select **Re-run all jobs**.
![Re-run checks drop-down menu](/assets/images/help/repository/rerun-checks-drop-down-updated.png)
{% endif %}

{% endwebui %}

{% cli %}

{% data reusables.cli.cli-learn-more %}

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.

```shell
gh run rerun <em>run-id</em>
```

To view the progress of the workflow run, use the `run watch` subcommand and select the run from the interactive list.

```shell
gh run watch
```

{% endcli %}

{% ifversion fpt or ghes > 3.2 or ghae-issue-4721 %}
### Reviewing previous workflow runs

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).

{% data reusables.repositories.navigate-to-repo %}
{% data reusables.repositories.actions-tab %}
{% data reusables.repositories.navigate-to-workflow %}
{% data reusables.repositories.view-run %}
1. Any previous run attempts are shown in the left pane.
![Rerun workflow](/assets/images/help/settings/actions-review-workflow-rerun.png)
1. Click an entry to view its results.

{% endif %}

0 comments on commit c28ae8b

Please sign in to comment.