Skip to content

Commit

Permalink
feat: enable artifact retention days (#88)
Browse files Browse the repository at this point in the history
* feat: enable artifact retention days

* docs: bump version in readme

---------

Co-authored-by: Miroslav Jonaš <missing.manual@gmail.com>
  • Loading branch information
brianespinosa and meeroslav committed Nov 17, 2023
1 parent 76feeb7 commit 81f1194
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 7 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/nx-cloud-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,10 @@ on:
required: false
type: string
default: "nx-main-artifacts"
artifacts-retention-days:
required: false
type: number
default: 90
working-directory:
required: false
type: string
Expand Down Expand Up @@ -367,3 +371,4 @@ jobs:
with:
name: ${{ inputs.artifacts-name }}
path: ${{ inputs.artifacts-path }}
retention-days: ${{ inputs.artifacts-retention-days }}
18 changes: 12 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ concurrency:
jobs:
main:
name: Nx Cloud - Main Job
uses: nrwl/ci/.github/workflows/nx-cloud-main.yml@v0.13.2
uses: nrwl/ci/.github/workflows/nx-cloud-main.yml@v0.14.0
with:
# NOTE: Here we are using the special `nx-cloud record` command to ensure that any commands we run that do not go through the cloud task runner natively
# (i.e. anything that starts with `nx run`/`nx run-many`/`nx affected --target`), are still captured in the Nx Cloud UI and Github App comment for
Expand All @@ -74,7 +74,7 @@ jobs:
agents:
name: Nx Cloud - Agents
uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.13.2
uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.14.0
with:
number-of-agents: 3
```
Expand Down Expand Up @@ -109,15 +109,15 @@ concurrency:
jobs:
main:
name: Nx Cloud - Main Job
uses: nrwl/ci/.github/workflows/nx-cloud-main.yml@v0.13.2
uses: nrwl/ci/.github/workflows/nx-cloud-main.yml@v0.14.0
secrets:
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
NX_CLOUD_AUTH_TOKEN: ${{ secrets.NX_CLOUD_AUTH_TOKEN }}
with: ...

agents:
name: Nx Cloud - Agents
uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.13.2
uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.14.0
secrets:
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
NX_CLOUD_AUTH_TOKEN: ${{ secrets.NX_CLOUD_AUTH_TOKEN }}
Expand All @@ -133,7 +133,7 @@ See the annotated configuration below for all explicitly supported secret values
<!-- start configuration-options-for-the-main-job -->

```yaml
- uses: nrwl/ci/.github/workflows/nx-cloud-main.yml@v0.13.2
- uses: nrwl/ci/.github/workflows/nx-cloud-main.yml@v0.14.0
# [OPTIONAL] Explicitly supported secret values which can be passed into the workflow from your outer workflow run.
#
# NOTE: You cannot access values from ${{ secrets }} beyond what is explicitly specified here because of the limitations of reusable Github workflows
Expand Down Expand Up @@ -239,6 +239,12 @@ See the annotated configuration below for all explicitly supported secret values
# NOTE: This input only has an effect if used with the `artifacts-path` input.
# Default: "nx-main-artifacts"
artifacts-name: ""

# [OPTIONAL] The number of days artifacts will be retained.
#
# NOTE: This input only has an effect if used with the `artifacts-path` input.
# Default: 90
artifacts-retention-days: ""

# [OPTIONAL] If you want to override GitHub's default timeout provide a timeout expressed in minutes.
#
Expand All @@ -258,7 +264,7 @@ See the annotated configuration below for all explicitly supported secret values
<!-- start configuration-options-for-agent-jobs -->

```yaml
- uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.13.2
- uses: nrwl/ci/.github/workflows/nx-cloud-agents.yml@v0.14.0
# [OPTIONAL] Explicitly supported secret values which can be passed into the workflow from your outer workflow run.
#
# NOTE: You cannot access values from ${{ secrets }} beyond what is explicitly specified here because of the limitations of reusable Github workflows
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"private": true,
"version": "0.13.3",
"version": "0.14.0",
"description": "This package.json is here purely to control the version of the Action, in combination with https://github.com/JamesHenry/publish-shell-action"
}

0 comments on commit 81f1194

Please sign in to comment.