From a540798efc94038496e35fcb981df21bec7e01b0 Mon Sep 17 00:00:00 2001 From: Siara <108543037+SiaraMist@users.noreply.github.com> Date: Tue, 30 Jul 2024 15:33:36 -0700 Subject: [PATCH] Relocate articles into new "About GitHub Actions" and "Writing workflows" categories (#51761) --- .../about-continuous-deployment.md | 3 +- .../about-continuous-integration.md | 1 + content/actions/about-github-actions/index.md | 14 ++ .../understanding-github-actions.md | 2 + .../automating-builds-and-tests/index.md | 1 - .../deployment/about-deployments/index.md | 1 - content/actions/guides.md | 16 +-- .../running-scripts-before-or-after-a-job.md | 2 +- content/actions/index.md | 27 ++-- .../essential-features-of-github-actions.md | 131 ------------------ content/actions/learn-github-actions/index.md | 29 ---- content/actions/using-jobs/index.md | 23 --- content/actions/using-workflows/index.md | 7 - .../adding-scripts-to-your-workflow.md | 59 ++++++++ .../assigning-permissions-to-jobs.md | 2 + ...hing-dependencies-to-speed-up-workflows.md | 1 + .../contexts.md | 1 + .../defining-outputs-for-jobs.md | 2 + .../expressions.md | 2 + .../finding-and-customizing-actions.md | 1 + .../choosing-what-your-workflow-does/index.md | 29 ++++ .../setting-default-values-for-jobs.md | 2 + .../storing-workflow-data-as-artifacts.md | 1 + .../using-a-matrix-for-your-jobs.md | 1 + .../using-concurrency.md | 2 + .../using-environments-for-deployment.md | 1 + .../using-github-cli-in-workflows.md | 1 + .../using-jobs-in-a-workflow.md | 2 + .../variables.md | 1 + .../workflow-commands-for-github-actions.md | 1 + .../events-that-trigger-workflows.md | 1 + .../choosing-when-your-workflow-runs/index.md | 14 ++ .../triggering-a-workflow.md | 2 + ...ing-conditions-to-control-job-execution.md | 2 + .../choosing-the-runner-for-a-job.md | 2 + .../index.md | 13 ++ .../running-jobs-in-a-container.md | 2 + content/actions/writing-workflows/index.md | 19 +++ .../{ => writing-workflows}/quickstart.md | 1 + .../using-starter-workflows.md | 1 + .../workflow-syntax-for-github-actions.md | 3 +- content/github-cli/index.md | 2 +- data/learning-tracks/actions.yml | 9 +- data/learning-tracks/admin.yml | 4 +- 44 files changed, 216 insertions(+), 225 deletions(-) rename content/actions/{deployment/about-deployments => about-github-actions}/about-continuous-deployment.md (96%) rename content/actions/{automating-builds-and-tests => about-github-actions}/about-continuous-integration.md (98%) create mode 100644 content/actions/about-github-actions/index.md rename content/actions/{learn-github-actions => about-github-actions}/understanding-github-actions.md (98%) delete mode 100644 content/actions/learn-github-actions/essential-features-of-github-actions.md delete mode 100644 content/actions/learn-github-actions/index.md delete mode 100644 content/actions/using-jobs/index.md create mode 100644 content/actions/writing-workflows/choosing-what-your-workflow-does/adding-scripts-to-your-workflow.md rename content/actions/{using-jobs => writing-workflows/choosing-what-your-workflow-does}/assigning-permissions-to-jobs.md (94%) rename content/actions/{using-workflows => writing-workflows/choosing-what-your-workflow-does}/caching-dependencies-to-speed-up-workflows.md (99%) rename content/actions/{learn-github-actions => writing-workflows/choosing-what-your-workflow-does}/contexts.md (99%) rename content/actions/{using-jobs => writing-workflows/choosing-what-your-workflow-does}/defining-outputs-for-jobs.md (82%) rename content/actions/{learn-github-actions => writing-workflows/choosing-what-your-workflow-does}/expressions.md (99%) rename content/actions/{learn-github-actions => writing-workflows/choosing-what-your-workflow-does}/finding-and-customizing-actions.md (99%) create mode 100644 content/actions/writing-workflows/choosing-what-your-workflow-does/index.md rename content/actions/{using-jobs => writing-workflows/choosing-what-your-workflow-does}/setting-default-values-for-jobs.md (92%) rename content/actions/{using-workflows => writing-workflows/choosing-what-your-workflow-does}/storing-workflow-data-as-artifacts.md (99%) rename content/actions/{using-jobs => writing-workflows/choosing-what-your-workflow-does}/using-a-matrix-for-your-jobs.md (96%) rename content/actions/{using-jobs => writing-workflows/choosing-what-your-workflow-does}/using-concurrency.md (96%) rename content/actions/{using-jobs => writing-workflows/choosing-what-your-workflow-does}/using-environments-for-deployment.md (94%) rename content/actions/{using-workflows => writing-workflows/choosing-what-your-workflow-does}/using-github-cli-in-workflows.md (97%) rename content/actions/{using-jobs => writing-workflows/choosing-what-your-workflow-does}/using-jobs-in-a-workflow.md (90%) rename content/actions/{learn-github-actions => writing-workflows/choosing-what-your-workflow-does}/variables.md (99%) rename content/actions/{using-workflows => writing-workflows/choosing-what-your-workflow-does}/workflow-commands-for-github-actions.md (99%) rename content/actions/{using-workflows => writing-workflows/choosing-when-your-workflow-runs}/events-that-trigger-workflows.md (99%) create mode 100644 content/actions/writing-workflows/choosing-when-your-workflow-runs/index.md rename content/actions/{using-workflows => writing-workflows/choosing-when-your-workflow-runs}/triggering-a-workflow.md (99%) rename content/actions/{using-jobs => writing-workflows/choosing-when-your-workflow-runs}/using-conditions-to-control-job-execution.md (91%) rename content/actions/{using-jobs => writing-workflows/choosing-where-your-workflow-runs}/choosing-the-runner-for-a-job.md (90%) create mode 100644 content/actions/writing-workflows/choosing-where-your-workflow-runs/index.md rename content/actions/{using-jobs => writing-workflows/choosing-where-your-workflow-runs}/running-jobs-in-a-container.md (93%) create mode 100644 content/actions/writing-workflows/index.md rename content/actions/{ => writing-workflows}/quickstart.md (99%) rename content/actions/{learn-github-actions => writing-workflows}/using-starter-workflows.md (98%) rename content/actions/{using-workflows => writing-workflows}/workflow-syntax-for-github-actions.md (99%) diff --git a/content/actions/deployment/about-deployments/about-continuous-deployment.md b/content/actions/about-github-actions/about-continuous-deployment.md similarity index 96% rename from content/actions/deployment/about-deployments/about-continuous-deployment.md rename to content/actions/about-github-actions/about-continuous-deployment.md index 03f9b3e385..c12f32fefa 100644 --- a/content/actions/deployment/about-deployments/about-continuous-deployment.md +++ b/content/actions/about-github-actions/about-continuous-deployment.md @@ -1,5 +1,6 @@ --- title: About continuous deployment +shortTitle: Continuous deployment intro: 'You can create custom continuous deployment (CD) workflows directly in your {% data variables.product.prodname_dotcom %} repository with {% data variables.product.prodname_actions %}.' versions: fpt: '*' @@ -8,9 +9,9 @@ versions: type: overview redirect_from: - /actions/deployment/about-continuous-deployment + - /actions/deployment/about-deployments/about-continuous-deployment topics: - CD -shortTitle: About continuous deployment --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/automating-builds-and-tests/about-continuous-integration.md b/content/actions/about-github-actions/about-continuous-integration.md similarity index 98% rename from content/actions/automating-builds-and-tests/about-continuous-integration.md rename to content/actions/about-github-actions/about-continuous-integration.md index a8b1732182..6aae0a7f30 100644 --- a/content/actions/automating-builds-and-tests/about-continuous-integration.md +++ b/content/actions/about-github-actions/about-continuous-integration.md @@ -7,6 +7,7 @@ redirect_from: - /actions/automating-your-workflow-with-github-actions/about-continuous-integration - /actions/building-and-testing-code-with-continuous-integration/about-continuous-integration - /actions/guides/about-continuous-integration + - /actions/automating-builds-and-tests/about-continuous-integration versions: fpt: '*' ghes: '*' diff --git a/content/actions/about-github-actions/index.md b/content/actions/about-github-actions/index.md new file mode 100644 index 0000000000..fc8b1a2ded --- /dev/null +++ b/content/actions/about-github-actions/index.md @@ -0,0 +1,14 @@ +--- +title: About GitHub Actions +shortTitle: About GitHub Actions +intro: '{% data variables.product.prodname_actions %} is a tool that you can use to build automations to assist with each stage of the software development lifecycle. This section describes {% data variables.product.prodname_actions %} concepts, common terminology, and some high level use cases.' +versions: + fpt: '*' + ghes: '*' + ghec: '*' +children: + - /understanding-github-actions + - /about-continuous-integration + - /about-continuous-deployment +--- + diff --git a/content/actions/learn-github-actions/understanding-github-actions.md b/content/actions/about-github-actions/understanding-github-actions.md similarity index 98% rename from content/actions/learn-github-actions/understanding-github-actions.md rename to content/actions/about-github-actions/understanding-github-actions.md index 32e44186ab..879968201e 100644 --- a/content/actions/learn-github-actions/understanding-github-actions.md +++ b/content/actions/about-github-actions/understanding-github-actions.md @@ -7,6 +7,8 @@ redirect_from: - /actions/automating-your-workflow-with-github-actions/core-concepts-for-github-actions - /actions/getting-started-with-github-actions/core-concepts-for-github-actions - /actions/learn-github-actions/introduction-to-github-actions + - /actions/learn-github-actions/understanding-github-actions + - /actions/learn-github-actions/essential-features-of-github-actions versions: fpt: '*' ghes: '*' diff --git a/content/actions/automating-builds-and-tests/index.md b/content/actions/automating-builds-and-tests/index.md index 69b611085a..897c33724a 100644 --- a/content/actions/automating-builds-and-tests/index.md +++ b/content/actions/automating-builds-and-tests/index.md @@ -16,7 +16,6 @@ redirect_from: - /actions/guides/building-and-testing-nodejs-or-python - /actions/automating-builds-and-tests/building-and-testing-nodejs-or-python children: - - /about-continuous-integration - /building-and-testing-go - /building-and-testing-java-with-ant - /building-and-testing-java-with-gradle diff --git a/content/actions/deployment/about-deployments/index.md b/content/actions/deployment/about-deployments/index.md index 0f98a41d10..964c6cdd0e 100644 --- a/content/actions/deployment/about-deployments/index.md +++ b/content/actions/deployment/about-deployments/index.md @@ -7,7 +7,6 @@ versions: ghes: '*' ghec: '*' children: - - /about-continuous-deployment - /deploying-with-github-actions --- diff --git a/content/actions/guides.md b/content/actions/guides.md index 4f28868a7f..0060d45e3c 100644 --- a/content/actions/guides.md +++ b/content/actions/guides.md @@ -1,5 +1,5 @@ --- -title: Guides for {% data variables.product.prodname_actions %} +title: 'Guides for {% data variables.product.prodname_actions %}' intro: 'These guides for {% data variables.product.prodname_actions %} include specific use cases and examples to help you configure workflows.' allowTitleToDifferFromFilename: true layout: product-guides @@ -14,16 +14,16 @@ learningTracks: - hosting_your_own_runners - create_actions includeGuides: - - /actions/quickstart - - /actions/learn-github-actions/understanding-github-actions + - /actions/writing-workflows/quickstart + - /actions/about-github-actions/understanding-github-actions - /actions/creating-actions/creating-a-docker-container-action - - /actions/learn-github-actions/using-starter-workflows + - /actions/writing-workflows/using-starter-workflows - /actions/automating-builds-and-tests/building-and-testing-python - /actions/automating-builds-and-tests/building-and-testing-nodejs - /actions/publishing-packages/about-packaging-with-github-actions - /actions/publishing-packages/publishing-docker-images - - /actions/using-workflows/caching-dependencies-to-speed-up-workflows - - /actions/automating-builds-and-tests/about-continuous-integration + - /actions/writing-workflows/choosing-what-your-workflow-does/caching-dependencies-to-speed-up-workflows + - /actions/about-github-actions/about-continuous-integration - /actions/automating-builds-and-tests/building-and-testing-powershell - /actions/automating-builds-and-tests/building-and-testing-ruby - /actions/automating-builds-and-tests/building-and-testing-java-with-maven @@ -35,13 +35,12 @@ includeGuides: - /actions/publishing-packages/publishing-nodejs-packages - /actions/publishing-packages/publishing-java-packages-with-maven - /actions/publishing-packages/publishing-java-packages-with-gradle - - /actions/using-workflows/storing-workflow-data-as-artifacts + - /actions/writing-workflows/choosing-what-your-workflow-does/storing-workflow-data-as-artifacts - /actions/using-containerized-services/about-service-containers - /actions/using-containerized-services/creating-redis-service-containers - /actions/using-containerized-services/creating-postgresql-service-containers - /actions/deployment/deploying-to-your-cloud-provider/deploying-to-amazon-elastic-container-service - /actions/deployment/deploying-to-your-cloud-provider/deploying-to-google-kubernetes-engine - - /actions/learn-github-actions/essential-features-of-github-actions - /actions/security-guides/security-hardening-for-github-actions - /actions/creating-actions/about-custom-actions - /actions/creating-actions/creating-a-javascript-action @@ -69,3 +68,4 @@ includeGuides: - /actions/deployment/deploying-to-your-cloud-provider/deploying-to-azure/deploying-to-azure-static-web-app - /actions/deployment/deploying-to-your-cloud-provider/deploying-to-azure/deploying-to-azure-kubernetes-service --- + diff --git a/content/actions/hosting-your-own-runners/managing-self-hosted-runners/running-scripts-before-or-after-a-job.md b/content/actions/hosting-your-own-runners/managing-self-hosted-runners/running-scripts-before-or-after-a-job.md index b9bce5f66e..bcf37637d6 100644 --- a/content/actions/hosting-your-own-runners/managing-self-hosted-runners/running-scripts-before-or-after-a-job.md +++ b/content/actions/hosting-your-own-runners/managing-self-hosted-runners/running-scripts-before-or-after-a-job.md @@ -77,7 +77,7 @@ If you get a "permission denied" error when you attempt to run a script, make su chmod +x PATH/TO/FILE ``` -For information about using workflows to run scripts, see "[AUTOTITLE](/actions/learn-github-actions/essential-features-of-github-actions#adding-scripts-to-your-workflow)." +For information about using workflows to run scripts, see "[AUTOTITLE](/actions/writing-workflows/choosing-what-your-workflow-does/adding-scripts-to-your-workflow)." ### No timeout setting diff --git a/content/actions/index.md b/content/actions/index.md index 83e156544d..9c3960e085 100644 --- a/content/actions/index.md +++ b/content/actions/index.md @@ -3,28 +3,28 @@ title: '{% data variables.product.prodname_actions %} documentation' shortTitle: '{% data variables.product.prodname_actions %}' intro: 'Automate, customize, and execute your software development workflows right in your repository with {% data variables.product.prodname_actions %}. You can discover, create, and share actions to perform any job you''d like, including CI/CD, and combine actions in a completely customized workflow.' introLinks: - overview: /actions/learn-github-actions/understanding-github-actions - quickstart: /actions/quickstart + overview: /actions/about-github-actions/understanding-github-actions + quickstart: /actions/writing-workflows/quickstart featuredLinks: startHere: - - /actions/learn-github-actions + - /actions/writing-workflows - /actions/examples - - /actions/automating-builds-and-tests/about-continuous-integration + - /actions/about-github-actions/about-continuous-integration - /actions/deployment/about-deployments/deploying-with-github-actions - /actions/publishing-packages/about-packaging-with-github-actions - /actions/monitoring-and-troubleshooting-workflows guideCards: - - /actions/learn-github-actions/using-starter-workflows + - /actions/writing-workflows/using-starter-workflows - /actions/publishing-packages/publishing-nodejs-packages - /actions/automating-builds-and-tests/building-and-testing-powershell popular: - - /actions/using-workflows/workflow-syntax-for-github-actions - - /actions/learn-github-actions + - /actions/writing-workflows/workflow-syntax-for-github-actions + - /actions/writing-workflows - /actions/examples - - /actions/using-workflows/events-that-trigger-workflows - - /actions/learn-github-actions/contexts - - /actions/learn-github-actions/expressions - - /actions/learn-github-actions/variables + - /actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows + - /actions/writing-workflows/choosing-what-your-workflow-does/contexts + - /actions/writing-workflows/choosing-what-your-workflow-does/expressions + - /actions/writing-workflows/choosing-what-your-workflow-does/variables - /actions/security-guides/using-secrets-in-github-actions changelog: label: actions @@ -42,11 +42,10 @@ versions: ghes: '*' ghec: '*' children: - - /quickstart - - /learn-github-actions + - /about-github-actions - /examples + - /writing-workflows - /using-workflows - - /using-jobs - /managing-workflow-runs - /automating-builds-and-tests - /deployment diff --git a/content/actions/learn-github-actions/essential-features-of-github-actions.md b/content/actions/learn-github-actions/essential-features-of-github-actions.md deleted file mode 100644 index df21f2a459..0000000000 --- a/content/actions/learn-github-actions/essential-features-of-github-actions.md +++ /dev/null @@ -1,131 +0,0 @@ ---- -title: Essential features of GitHub Actions -shortTitle: Essential features -intro: '{% data variables.product.prodname_actions %} are designed to help you build robust and dynamic automations. This guide will show you how to craft {% data variables.product.prodname_actions %} workflows that include environment variables, customized scripts, and more.' -versions: - fpt: '*' - ghes: '*' - ghec: '*' -type: overview -topics: - - Fundamentals ---- - -{% data reusables.actions.enterprise-github-hosted-runners %} - -## Overview - -{% data variables.product.prodname_actions %} allow you to customize your workflows to meet the unique needs of your application and team. In this guide, we'll discuss some of the essential customization techniques such as using variables, running scripts, and sharing data and artifacts between jobs. - -## Using variables in your workflows - -{% data variables.product.prodname_actions %} include default environment variables for each workflow run. If you need to use custom environment variables, you can set these in your YAML workflow file. This example demonstrates how to create custom variables named `POSTGRES_HOST` and `POSTGRES_PORT`. These variables are then available to the `node client.js` script. - -```yaml -jobs: - example-job: - runs-on: ubuntu-latest - steps: - - name: Connect to PostgreSQL - run: node client.js - env: - POSTGRES_HOST: postgres - POSTGRES_PORT: 5432 -``` - -For more information, see "[AUTOTITLE](/actions/learn-github-actions/variables#default-environment-variables)." - -## Adding scripts to your workflow - -You can use a {% data variables.product.prodname_actions %} workflow to run scripts and shell commands, which are then executed on the assigned runner. This example demonstrates how to use the `run` keyword to execute the command `npm install -g bats` on the runner. - -```yaml -jobs: - example-job: - runs-on: ubuntu-latest - steps: - - run: npm install -g bats -``` - -To use a workflow to run a script stored in your repository you must first check out the repository to the runner. Having done this, you can use the `run` keyword to run the script on the runner. The following example runs two scripts, each in a separate job step. The location of the scripts on the runner is specified by setting a default working directory for run commands. For more information, see "[AUTOTITLE](/actions/using-jobs/setting-default-values-for-jobs)." - -```yaml -jobs: - example-job: - runs-on: ubuntu-latest - defaults: - run: - working-directory: ./scripts - steps: - - name: Check out the repository to the runner - uses: {% data reusables.actions.action-checkout %} - - name: Run a script - run: ./my-script.sh - - name: Run another script - run: ./my-other-script.sh -``` - -Any scripts that you want a workflow job to run must be executable. You can do this either within the workflow by passing the script as an argument to the interpreter that will run the script - for example, `run: bash script.sh` - or by making the file itself executable. You can give the file the execute permission by using the command `git update-index --chmod=+x PATH/TO/YOUR/script.sh` locally, then committing and pushing the file to the repository. Alternatively, for workflows that are run on Linux and Mac runners, you can add a command to give the file the execute permission in the workflow job, prior to running the script: - -```yaml -jobs: - example-job: - runs-on: ubuntu-latest - defaults: - run: - working-directory: ./scripts - steps: - - name: Check out the repository to the runner - uses: {% data reusables.actions.action-checkout %} - - name: Make the script files executable - run: chmod +x my-script.sh my-other-script.sh - - name: Run the scripts - run: | - ./my-script.sh - ./my-other-script.sh -``` - -For more information about the `run` keyword, see "[AUTOTITLE](/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun)." - -## Sharing data between jobs - -If your job generates files that you want to share with another job in the same workflow, or if you want to save the files for later reference, you can store them in {% data variables.product.prodname_dotcom %} as _artifacts_. Artifacts are the files created when you build and test your code. For example, artifacts might include binary or package files, test results, screenshots, or log files. Artifacts are associated with the workflow run where they were created and can be used by another job. {% data reusables.actions.reusable-workflow-artifacts %} - -For example, you can create a file and then upload it as an artifact. - -```yaml -jobs: - example-job: - name: Save output - runs-on: ubuntu-latest - steps: - - shell: bash - run: | - expr 1 + 1 > output.log - - name: Upload output file - uses: {% data reusables.actions.action-upload-artifact %} - with: - name: output-log-file - path: output.log -``` - -To download an artifact from a separate workflow run, you can use the `actions/download-artifact` action. For example, you can download the artifact named `output-log-file`. - -```yaml -jobs: - example-job: - runs-on: ubuntu-latest - steps: - - name: Download a single artifact - uses: {% data reusables.actions.action-download-artifact %} - with: - name: output-log-file -``` - -To download an artifact from the same workflow run, your download job should specify `needs: upload-job-name` so it doesn't start until the upload job finishes. - -For more information about artifacts, see "[AUTOTITLE](/actions/using-workflows/storing-workflow-data-as-artifacts)." - -## Next steps - -To continue learning about {% data variables.product.prodname_actions %}, see "[AUTOTITLE](/actions/using-workflows/about-workflows)." diff --git a/content/actions/learn-github-actions/index.md b/content/actions/learn-github-actions/index.md deleted file mode 100644 index 57eaee541e..0000000000 --- a/content/actions/learn-github-actions/index.md +++ /dev/null @@ -1,29 +0,0 @@ ---- -title: Learn GitHub Actions -shortTitle: Learn GitHub Actions -intro: 'Whether you are new to {% data variables.product.prodname_actions %} or interested in learning all they have to offer, this guide will help you use {% data variables.product.prodname_actions %} to accelerate your application development workflows.' -redirect_from: - - /articles/about-github-actions - - /actions/getting-started-with-github-actions - - /actions/getting-started-with-github-actions/about-github-actions - - /actions/getting-started-with-github-actions/overview - - /actions/getting-started-with-github-actions/getting-started-with-github-actions - - /articles/getting-started-with-github-actions - - /github/automating-your-workflow-with-github-actions/about-github-actions - - /actions/automating-your-workflow-with-github-actions/about-github-actions - - /github/automating-your-workflow-with-github-actions/getting-started-with-github-actions - - /actions/automating-your-workflow-with-github-actions/getting-started-with-github-actions -versions: - fpt: '*' - ghes: '*' - ghec: '*' -children: - - /understanding-github-actions - - /finding-and-customizing-actions - - /essential-features-of-github-actions - - /expressions - - /contexts - - /variables - - /using-starter-workflows ---- - diff --git a/content/actions/using-jobs/index.md b/content/actions/using-jobs/index.md deleted file mode 100644 index 867d8f936d..0000000000 --- a/content/actions/using-jobs/index.md +++ /dev/null @@ -1,23 +0,0 @@ ---- -title: Using jobs -shortTitle: Using jobs -intro: 'Creating and managing {% data variables.product.prodname_actions %} jobs.' -redirect_from: - - /actions/jobs -versions: - fpt: '*' - ghes: '*' - ghec: '*' -children: - - /using-jobs-in-a-workflow - - /choosing-the-runner-for-a-job - - /using-conditions-to-control-job-execution - - /using-a-matrix-for-your-jobs - - /using-concurrency - - /using-environments-for-deployment - - /running-jobs-in-a-container - - /setting-default-values-for-jobs - - /assigning-permissions-to-jobs - - /defining-outputs-for-jobs ---- - diff --git a/content/actions/using-workflows/index.md b/content/actions/using-workflows/index.md index 7d1af2ac95..91da7eefdc 100644 --- a/content/actions/using-workflows/index.md +++ b/content/actions/using-workflows/index.md @@ -21,18 +21,11 @@ versions: ghec: '*' children: - /about-workflows - - /triggering-a-workflow - /manually-running-a-workflow - /disabling-and-enabling-a-workflow - - /events-that-trigger-workflows - - /workflow-syntax-for-github-actions - - /workflow-commands-for-github-actions - /avoiding-duplication - /reusing-workflows - /required-workflows - - /caching-dependencies-to-speed-up-workflows - - /storing-workflow-data-as-artifacts - /creating-starter-workflows-for-your-organization - - /using-github-cli-in-workflows --- diff --git a/content/actions/writing-workflows/choosing-what-your-workflow-does/adding-scripts-to-your-workflow.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/adding-scripts-to-your-workflow.md new file mode 100644 index 0000000000..d67498211b --- /dev/null +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/adding-scripts-to-your-workflow.md @@ -0,0 +1,59 @@ +--- +title: Adding scripts to your workflow +shortTitle: Add scripts +intro: 'You can use {% data variables.product.prodname_actions %} workflows to run scripts.' +versions: + fpt: '*' + ghes: '*' + ghec: '*' +--- + +You can use a {% data variables.product.prodname_actions %} workflow to run scripts and shell commands, which are then executed on the assigned runner. This example demonstrates how to use the `run` keyword to execute the command `npm install -g bats` on the runner. + +```yaml +jobs: + example-job: + runs-on: ubuntu-latest + steps: + - run: npm install -g bats +``` + +To use a workflow to run a script stored in your repository you must first check out the repository to the runner. Having done this, you can use the `run` keyword to run the script on the runner. The following example runs two scripts, each in a separate job step. The location of the scripts on the runner is specified by setting a default working directory for run commands. For more information, see "[AUTOTITLE](/actions/using-jobs/setting-default-values-for-jobs)." + +```yaml +jobs: + example-job: + runs-on: ubuntu-latest + defaults: + run: + working-directory: ./scripts + steps: + - name: Check out the repository to the runner + uses: {% data reusables.actions.action-checkout %} + - name: Run a script + run: ./my-script.sh + - name: Run another script + run: ./my-other-script.sh +``` + +Any scripts that you want a workflow job to run must be executable. You can do this either within the workflow by passing the script as an argument to the interpreter that will run the script - for example, `run: bash script.sh` - or by making the file itself executable. You can give the file the execute permission by using the command `git update-index --chmod=+x PATH/TO/YOUR/script.sh` locally, then committing and pushing the file to the repository. Alternatively, for workflows that are run on Linux and Mac runners, you can add a command to give the file the execute permission in the workflow job, prior to running the script: + +```yaml +jobs: + example-job: + runs-on: ubuntu-latest + defaults: + run: + working-directory: ./scripts + steps: + - name: Check out the repository to the runner + uses: {% data reusables.actions.action-checkout %} + - name: Make the script files executable + run: chmod +x my-script.sh my-other-script.sh + - name: Run the scripts + run: | + ./my-script.sh + ./my-other-script.sh +``` + +For more information about the `run` keyword, see "[AUTOTITLE](/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun)." diff --git a/content/actions/using-jobs/assigning-permissions-to-jobs.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/assigning-permissions-to-jobs.md similarity index 94% rename from content/actions/using-jobs/assigning-permissions-to-jobs.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/assigning-permissions-to-jobs.md index eb97fdffd1..691240d917 100644 --- a/content/actions/using-jobs/assigning-permissions-to-jobs.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/assigning-permissions-to-jobs.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '> 3.1' ghec: '*' +redirect_from: + - /actions/using-jobs/assigning-permissions-to-jobs --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/using-workflows/caching-dependencies-to-speed-up-workflows.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/caching-dependencies-to-speed-up-workflows.md similarity index 99% rename from content/actions/using-workflows/caching-dependencies-to-speed-up-workflows.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/caching-dependencies-to-speed-up-workflows.md index 064eeb6325..ea455ca382 100644 --- a/content/actions/using-workflows/caching-dependencies-to-speed-up-workflows.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/caching-dependencies-to-speed-up-workflows.md @@ -8,6 +8,7 @@ redirect_from: - /actions/configuring-and-managing-workflows/caching-dependencies-to-speed-up-workflows - /actions/guides/caching-dependencies-to-speed-up-workflows - /actions/advanced-guides/caching-dependencies-to-speed-up-workflows + - /actions/using-workflows/caching-dependencies-to-speed-up-workflows versions: feature: actions-caching type: tutorial diff --git a/content/actions/learn-github-actions/contexts.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/contexts.md similarity index 99% rename from content/actions/learn-github-actions/contexts.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/contexts.md index fddf3655e5..14156bfe42 100644 --- a/content/actions/learn-github-actions/contexts.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/contexts.md @@ -8,6 +8,7 @@ redirect_from: - /actions/automating-your-workflow-with-github-actions/contexts-and-expression-syntax-for-github-actions - /actions/reference/contexts-and-expression-syntax-for-github-actions - /actions/reference/context-and-expression-syntax-for-github-actions + - /actions/learn-github-actions/contexts versions: fpt: '*' ghes: '*' diff --git a/content/actions/using-jobs/defining-outputs-for-jobs.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/defining-outputs-for-jobs.md similarity index 82% rename from content/actions/using-jobs/defining-outputs-for-jobs.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/defining-outputs-for-jobs.md index b0cb5b6838..80c53cae9d 100644 --- a/content/actions/using-jobs/defining-outputs-for-jobs.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/defining-outputs-for-jobs.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '*' ghec: '*' +redirect_from: + - /actions/using-jobs/defining-outputs-for-jobs --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/learn-github-actions/expressions.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/expressions.md similarity index 99% rename from content/actions/learn-github-actions/expressions.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/expressions.md index f97f1c2185..5518ebe3c3 100644 --- a/content/actions/learn-github-actions/expressions.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/expressions.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '*' ghec: '*' +redirect_from: + - /actions/learn-github-actions/expressions --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/learn-github-actions/finding-and-customizing-actions.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/finding-and-customizing-actions.md similarity index 99% rename from content/actions/learn-github-actions/finding-and-customizing-actions.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/finding-and-customizing-actions.md index 8517a9bef2..40fc194f8c 100644 --- a/content/actions/learn-github-actions/finding-and-customizing-actions.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/finding-and-customizing-actions.md @@ -7,6 +7,7 @@ redirect_from: - /actions/automating-your-workflow-with-github-actions/using-actions-from-github-marketplace-in-your-workflow - /actions/getting-started-with-github-actions/using-actions-from-github-marketplace - /actions/getting-started-with-github-actions/using-community-workflows-and-actions + - /actions/learn-github-actions/finding-and-customizing-actions versions: fpt: '*' ghes: '*' diff --git a/content/actions/writing-workflows/choosing-what-your-workflow-does/index.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/index.md new file mode 100644 index 0000000000..48c3734178 --- /dev/null +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/index.md @@ -0,0 +1,29 @@ +--- +title: Choosing what your workflow does +shortTitle: Choose what workflows do +intro: 'Workflows automate tasks in your software development lifecycle. Many tasks that you manually complete can be converted to a {% data variables.product.prodname_actions %} workflow.' +redirect_from: + - /actions/using-jobs +versions: + fpt: '*' + ghes: '*' + ghec: '*' +children: + - /using-jobs-in-a-workflow + - /finding-and-customizing-actions + - /using-github-cli-in-workflows + - /workflow-commands-for-github-actions + - /adding-scripts-to-your-workflow + - /assigning-permissions-to-jobs + - /expressions + - /variables + - /contexts + - /defining-outputs-for-jobs + - /setting-default-values-for-jobs + - /using-environments-for-deployment + - /using-concurrency + - /using-a-matrix-for-your-jobs + - /caching-dependencies-to-speed-up-workflows + - /storing-workflow-data-as-artifacts +--- + diff --git a/content/actions/using-jobs/setting-default-values-for-jobs.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/setting-default-values-for-jobs.md similarity index 92% rename from content/actions/using-jobs/setting-default-values-for-jobs.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/setting-default-values-for-jobs.md index 97fd482e5a..016d4e60ef 100644 --- a/content/actions/using-jobs/setting-default-values-for-jobs.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/setting-default-values-for-jobs.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '*' ghec: '*' +redirect_from: + - /actions/using-jobs/setting-default-values-for-jobs --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/using-workflows/storing-workflow-data-as-artifacts.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/storing-workflow-data-as-artifacts.md similarity index 99% rename from content/actions/using-workflows/storing-workflow-data-as-artifacts.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/storing-workflow-data-as-artifacts.md index 3532188f18..2ae20cf2d6 100644 --- a/content/actions/using-workflows/storing-workflow-data-as-artifacts.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/storing-workflow-data-as-artifacts.md @@ -9,6 +9,7 @@ redirect_from: - /actions/configuring-and-managing-workflows/persisting-workflow-data-using-artifacts - /actions/guides/storing-workflow-data-as-artifacts - /actions/advanced-guides/storing-workflow-data-as-artifacts + - /actions/using-workflows/storing-workflow-data-as-artifacts versions: fpt: '*' ghes: '*' diff --git a/content/actions/using-jobs/using-a-matrix-for-your-jobs.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-a-matrix-for-your-jobs.md similarity index 96% rename from content/actions/using-jobs/using-a-matrix-for-your-jobs.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/using-a-matrix-for-your-jobs.md index 5312977ab1..06cfa45261 100644 --- a/content/actions/using-jobs/using-a-matrix-for-your-jobs.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-a-matrix-for-your-jobs.md @@ -8,6 +8,7 @@ versions: ghec: '*' redirect_from: - /actions/using-jobs/using-a-build-matrix-for-your-jobs + - /actions/using-jobs/using-a-matrix-for-your-jobs --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/using-jobs/using-concurrency.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-concurrency.md similarity index 96% rename from content/actions/using-jobs/using-concurrency.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/using-concurrency.md index 25cef3d7d8..c3fdb1a87d 100644 --- a/content/actions/using-jobs/using-concurrency.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-concurrency.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '> 3.1' ghec: '*' +redirect_from: + - /actions/using-jobs/using-concurrency --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/using-jobs/using-environments-for-deployment.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-environments-for-deployment.md similarity index 94% rename from content/actions/using-jobs/using-environments-for-deployment.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/using-environments-for-deployment.md index 3ba1ea3d9f..db8b1fa1f3 100644 --- a/content/actions/using-jobs/using-environments-for-deployment.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-environments-for-deployment.md @@ -8,6 +8,7 @@ versions: ghec: '*' redirect_from: - /actions/using-jobs/using-environments-for-jobs + - /actions/using-jobs/using-environments-for-deployment --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/using-workflows/using-github-cli-in-workflows.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-github-cli-in-workflows.md similarity index 97% rename from content/actions/using-workflows/using-github-cli-in-workflows.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/using-github-cli-in-workflows.md index f243e06081..1f3be5e885 100644 --- a/content/actions/using-workflows/using-github-cli-in-workflows.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-github-cli-in-workflows.md @@ -5,6 +5,7 @@ intro: 'You can script with {% data variables.product.prodname_cli %} in {% data redirect_from: - /actions/guides/using-github-cli-in-workflows - /actions/advanced-guides/using-github-cli-in-workflows + - /actions/using-workflows/using-github-cli-in-workflows versions: fpt: '*' ghes: '*' diff --git a/content/actions/using-jobs/using-jobs-in-a-workflow.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-jobs-in-a-workflow.md similarity index 90% rename from content/actions/using-jobs/using-jobs-in-a-workflow.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/using-jobs-in-a-workflow.md index ecb0619203..993a032faf 100644 --- a/content/actions/using-jobs/using-jobs-in-a-workflow.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/using-jobs-in-a-workflow.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '*' ghec: '*' +redirect_from: + - /actions/using-jobs/using-jobs-in-a-workflow --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/learn-github-actions/variables.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/variables.md similarity index 99% rename from content/actions/learn-github-actions/variables.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/variables.md index 9c0093f80d..4457ade054 100644 --- a/content/actions/learn-github-actions/variables.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/variables.md @@ -7,6 +7,7 @@ redirect_from: - /actions/configuring-and-managing-workflows/using-environment-variables - /actions/reference/environment-variables - /actions/learn-github-actions/environment-variables + - /actions/learn-github-actions/variables versions: fpt: '*' ghes: '*' diff --git a/content/actions/using-workflows/workflow-commands-for-github-actions.md b/content/actions/writing-workflows/choosing-what-your-workflow-does/workflow-commands-for-github-actions.md similarity index 99% rename from content/actions/using-workflows/workflow-commands-for-github-actions.md rename to content/actions/writing-workflows/choosing-what-your-workflow-does/workflow-commands-for-github-actions.md index 72d094242d..6e86da7b1a 100644 --- a/content/actions/using-workflows/workflow-commands-for-github-actions.md +++ b/content/actions/writing-workflows/choosing-what-your-workflow-does/workflow-commands-for-github-actions.md @@ -11,6 +11,7 @@ redirect_from: - /actions/reference/logging-commands-for-github-actions - /actions/reference/workflow-commands-for-github-actions - /actions/learn-github-actions/workflow-commands-for-github-actions + - /actions/using-workflows/workflow-commands-for-github-actions versions: fpt: '*' ghes: '*' diff --git a/content/actions/using-workflows/events-that-trigger-workflows.md b/content/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows.md similarity index 99% rename from content/actions/using-workflows/events-that-trigger-workflows.md rename to content/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows.md index 2833c76dba..0b6e8c8277 100644 --- a/content/actions/using-workflows/events-that-trigger-workflows.md +++ b/content/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows.md @@ -7,6 +7,7 @@ redirect_from: - /actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows - /actions/reference/events-that-trigger-workflows - /actions/learn-github-actions/events-that-trigger-workflows + - /actions/using-workflows/events-that-trigger-workflows versions: fpt: '*' ghes: '*' diff --git a/content/actions/writing-workflows/choosing-when-your-workflow-runs/index.md b/content/actions/writing-workflows/choosing-when-your-workflow-runs/index.md new file mode 100644 index 0000000000..7958c95b08 --- /dev/null +++ b/content/actions/writing-workflows/choosing-when-your-workflow-runs/index.md @@ -0,0 +1,14 @@ +--- +title: Choosing when your workflow runs +shortTitle: Choose when workflows run +intro: You can configure workflows to run on a schedule or to run when certain events happen. +versions: + fpt: '*' + ghes: '*' + ghec: '*' +children: + - /triggering-a-workflow + - /using-conditions-to-control-job-execution + - /events-that-trigger-workflows +--- + diff --git a/content/actions/using-workflows/triggering-a-workflow.md b/content/actions/writing-workflows/choosing-when-your-workflow-runs/triggering-a-workflow.md similarity index 99% rename from content/actions/using-workflows/triggering-a-workflow.md rename to content/actions/writing-workflows/choosing-when-your-workflow-runs/triggering-a-workflow.md index 06b8c049bb..71f27c7e91 100644 --- a/content/actions/using-workflows/triggering-a-workflow.md +++ b/content/actions/writing-workflows/choosing-when-your-workflow-runs/triggering-a-workflow.md @@ -11,6 +11,8 @@ topics: - Workflows - CI - CD +redirect_from: + - /actions/using-workflows/triggering-a-workflow --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/using-jobs/using-conditions-to-control-job-execution.md b/content/actions/writing-workflows/choosing-when-your-workflow-runs/using-conditions-to-control-job-execution.md similarity index 91% rename from content/actions/using-jobs/using-conditions-to-control-job-execution.md rename to content/actions/writing-workflows/choosing-when-your-workflow-runs/using-conditions-to-control-job-execution.md index c76acbfe53..601967794e 100644 --- a/content/actions/using-jobs/using-conditions-to-control-job-execution.md +++ b/content/actions/writing-workflows/choosing-when-your-workflow-runs/using-conditions-to-control-job-execution.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '*' ghec: '*' +redirect_from: + - /actions/using-jobs/using-conditions-to-control-job-execution --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/using-jobs/choosing-the-runner-for-a-job.md b/content/actions/writing-workflows/choosing-where-your-workflow-runs/choosing-the-runner-for-a-job.md similarity index 90% rename from content/actions/using-jobs/choosing-the-runner-for-a-job.md rename to content/actions/writing-workflows/choosing-where-your-workflow-runs/choosing-the-runner-for-a-job.md index 0c3b63b66a..ff21f8983b 100644 --- a/content/actions/using-jobs/choosing-the-runner-for-a-job.md +++ b/content/actions/writing-workflows/choosing-where-your-workflow-runs/choosing-the-runner-for-a-job.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '*' ghec: '*' +redirect_from: + - /actions/using-jobs/choosing-the-runner-for-a-job --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/writing-workflows/choosing-where-your-workflow-runs/index.md b/content/actions/writing-workflows/choosing-where-your-workflow-runs/index.md new file mode 100644 index 0000000000..1a3a3dd857 --- /dev/null +++ b/content/actions/writing-workflows/choosing-where-your-workflow-runs/index.md @@ -0,0 +1,13 @@ +--- +title: Choosing where your workflow runs +shortTitle: Choose where workflows run +intro: You can specify the compute environment your jobs and workflows run in. +versions: + fpt: '*' + ghes: '*' + ghec: '*' +children: + - /choosing-the-runner-for-a-job + - /running-jobs-in-a-container +--- + diff --git a/content/actions/using-jobs/running-jobs-in-a-container.md b/content/actions/writing-workflows/choosing-where-your-workflow-runs/running-jobs-in-a-container.md similarity index 93% rename from content/actions/using-jobs/running-jobs-in-a-container.md rename to content/actions/writing-workflows/choosing-where-your-workflow-runs/running-jobs-in-a-container.md index 100469bcc4..ee375f636f 100644 --- a/content/actions/using-jobs/running-jobs-in-a-container.md +++ b/content/actions/writing-workflows/choosing-where-your-workflow-runs/running-jobs-in-a-container.md @@ -6,6 +6,8 @@ versions: fpt: '*' ghes: '*' ghec: '*' +redirect_from: + - /actions/using-jobs/running-jobs-in-a-container --- {% data reusables.actions.enterprise-github-hosted-runners %} diff --git a/content/actions/writing-workflows/index.md b/content/actions/writing-workflows/index.md new file mode 100644 index 0000000000..95b0af399b --- /dev/null +++ b/content/actions/writing-workflows/index.md @@ -0,0 +1,19 @@ +--- +title: Writing workflows +shortTitle: Write workflows +intro: '{% data variables.product.prodname_actions %} workflows can automate tasks throughout the software development lifecycle.' +redirect_from: + - /actions/learn-github-actions +versions: + fpt: '*' + ghes: '*' + ghec: '*' +children: + - /quickstart + - /using-starter-workflows + - /choosing-when-your-workflow-runs + - /choosing-where-your-workflow-runs + - /choosing-what-your-workflow-does + - /workflow-syntax-for-github-actions +--- + diff --git a/content/actions/quickstart.md b/content/actions/writing-workflows/quickstart.md similarity index 99% rename from content/actions/quickstart.md rename to content/actions/writing-workflows/quickstart.md index b196cb476e..914060af90 100644 --- a/content/actions/quickstart.md +++ b/content/actions/writing-workflows/quickstart.md @@ -4,6 +4,7 @@ intro: 'Try out the features of {% data variables.product.prodname_actions %} in allowTitleToDifferFromFilename: true redirect_from: - /actions/getting-started-with-github-actions/starting-with-preconfigured-workflow-templates + - /actions/quickstart versions: fpt: '*' ghes: '*' diff --git a/content/actions/learn-github-actions/using-starter-workflows.md b/content/actions/writing-workflows/using-starter-workflows.md similarity index 98% rename from content/actions/learn-github-actions/using-starter-workflows.md rename to content/actions/writing-workflows/using-starter-workflows.md index a70df4b808..96ba862288 100644 --- a/content/actions/learn-github-actions/using-starter-workflows.md +++ b/content/actions/writing-workflows/using-starter-workflows.md @@ -10,6 +10,7 @@ redirect_from: - /actions/guides/setting-up-continuous-integration-using-workflow-templates - /actions/learn-github-actions/using-workflow-templates - /actions/using-workflows/using-starter-workflows + - /actions/learn-github-actions/using-starter-workflows versions: fpt: '*' ghes: '*' diff --git a/content/actions/using-workflows/workflow-syntax-for-github-actions.md b/content/actions/writing-workflows/workflow-syntax-for-github-actions.md similarity index 99% rename from content/actions/using-workflows/workflow-syntax-for-github-actions.md rename to content/actions/writing-workflows/workflow-syntax-for-github-actions.md index 0350093bb8..a0d3cc4702 100644 --- a/content/actions/using-workflows/workflow-syntax-for-github-actions.md +++ b/content/actions/writing-workflows/workflow-syntax-for-github-actions.md @@ -8,6 +8,7 @@ redirect_from: - /actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions - /actions/reference/workflow-syntax-for-github-actions - /actions/learn-github-actions/workflow-syntax-for-github-actions + - /actions/using-workflows/workflow-syntax-for-github-actions versions: fpt: '*' ghes: '*' @@ -683,7 +684,7 @@ Using the `working-directory` keyword, you can specify the working directory of Alternatively, you can specify a default working directory for all `run` steps in a job, or for all `run` steps in the entire workflow. For more information, see "[`defaults.run.working-directory`](/actions/using-workflows/workflow-syntax-for-github-actions#defaultsrunworking-directory)" and "[`jobs..defaults.run.working-directory`](/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_iddefaultsrunworking-directory)." -You can also use a `run` step to run a script. For more information, see "[AUTOTITLE](/actions/learn-github-actions/essential-features-of-github-actions#adding-scripts-to-your-workflow)." +You can also use a `run` step to run a script. For more information, see "[AUTOTITLE](/actions/writing-workflows/choosing-what-your-workflow-does/adding-scripts-to-your-workflow)." ## `jobs..steps[*].shell` diff --git a/content/github-cli/index.md b/content/github-cli/index.md index ad85a790f2..122f56226c 100644 --- a/content/github-cli/index.md +++ b/content/github-cli/index.md @@ -16,7 +16,7 @@ featuredLinks: startHere: - /github-cli/github-cli/creating-github-cli-extensions - /github-cli/github-cli/using-github-cli-extensions - - /actions/using-workflows/using-github-cli-in-workflows + - /actions/writing-workflows/choosing-what-your-workflow-does/using-github-cli-in-workflows - /codespaces/developing-in-a-codespace/using-github-codespaces-with-github-cli popular: - /pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request diff --git a/data/learning-tracks/actions.yml b/data/learning-tracks/actions.yml index 987df03fa5..18572ec136 100644 --- a/data/learning-tracks/actions.yml +++ b/data/learning-tracks/actions.yml @@ -4,9 +4,8 @@ getting_started: Discover the possibilities of {% data variables.product.prodname_actions %} by creating your first workflow. guides: - - /actions/learn-github-actions/understanding-github-actions - - /actions/learn-github-actions/finding-and-customizing-actions - - /actions/learn-github-actions/essential-features-of-github-actions + - /actions/about-github-actions/understanding-github-actions + - /actions/writing-workflows/choosing-what-your-workflow-does/finding-and-customizing-actions - /actions/using-workflows/about-workflows - /actions/using-workflows/reusing-workflows - /actions/security-guides/security-hardening-for-github-actions @@ -20,7 +19,7 @@ adopting_github_actions_for_your_enterprise_ghec: guides: - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/about-github-actions-for-enterprises - - /actions/learn-github-actions/understanding-github-actions + - /actions/about-github-actions/understanding-github-actions - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/introducing-github-actions-to-your-enterprise - >- @@ -40,7 +39,7 @@ adopting_github_actions_for_your_enterprise_ghes: guides: - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/about-github-actions-for-enterprises - - /actions/learn-github-actions/understanding-github-actions + - /actions/about-github-actions/understanding-github-actions - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/introducing-github-actions-to-your-enterprise - >- diff --git a/data/learning-tracks/admin.yml b/data/learning-tracks/admin.yml index 9e45e9be23..c6a881a8fe 100644 --- a/data/learning-tracks/admin.yml +++ b/data/learning-tracks/admin.yml @@ -43,7 +43,7 @@ adopting_github_actions_for_your_enterprise_ghec: guides: - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/about-github-actions-for-enterprises - - /actions/learn-github-actions/understanding-github-actions + - /actions/about-github-actions/understanding-github-actions - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/introducing-github-actions-to-your-enterprise - >- @@ -63,7 +63,7 @@ adopting_github_actions_for_your_enterprise_ghes: guides: - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/about-github-actions-for-enterprises - - /actions/learn-github-actions/understanding-github-actions + - /actions/about-github-actions/understanding-github-actions - >- /admin/managing-github-actions-for-your-enterprise/getting-started-with-github-actions-for-your-enterprise/introducing-github-actions-to-your-enterprise - >-