Skip to content

Commit 6834ed7

Browse files
authored
Merge pull request #54112 from github/repo-sync
Repo sync
2 parents 20a3c8f + 6933714 commit 6834ed7

File tree

8 files changed

+20
-18
lines changed

8 files changed

+20
-18
lines changed

content/actions/use-cases-and-examples/building-and-testing/building-and-testing-java-with-ant.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -90,9 +90,9 @@ We recommend that you have a basic understanding of Java and the Ant framework.
9090

9191
You can use the same commands that you use locally to build and test your code.
9292

93-
The workflow template will run the default target specified in your _build.xml_ file. Your default target will commonly be set to build classes, run tests and package classes into their distributable format, for example, a JAR file.
93+
The workflow template will run the default target specified in your `build.xml` file. Your default target will commonly be set to build classes, run tests and package classes into their distributable format, for example, a JAR file.
9494

95-
If you use different commands to build your project, or you want to run a different target, you can specify those. For example, you may want to run the `jar` target that's configured in your `_build-ci.xml_` file.
95+
If you use different commands to build your project, or you want to run a different target, you can specify those. For example, you may want to run the `jar` target that's configured in your `build-ci.xml` file.
9696

9797
```yaml copy
9898
steps:

content/actions/use-cases-and-examples/building-and-testing/building-and-testing-java-with-gradle.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ You can use the same commands that you use locally to build and test your code.
103103

104104
The workflow template will run the `build` task by default. In the default Gradle configuration, this command will download dependencies, build classes, run tests, and package classes into their distributable format, for example, a JAR file.
105105

106-
If you use different commands to build your project, or you want to use a different task, you can specify those. For example, you may want to run the `package` task that's configured in your _ci.gradle_ file.
106+
If you use different commands to build your project, or you want to use a different task, you can specify those. For example, you may want to run the `package` task that's configured in your `ci.gradle` file.
107107

108108
```yaml copy
109109
steps:

content/actions/use-cases-and-examples/building-and-testing/building-and-testing-java-with-maven.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ You can use the same commands that you use locally to build and test your code.
9797

9898
The workflow template will run the `package` target by default. In the default Maven configuration, this command will download dependencies, build classes, run tests, and package classes into their distributable format, for example, a JAR file.
9999

100-
If you use different commands to build your project, or you want to use a different target, you can specify those. For example, you may want to run the `verify` target that's configured in a _pom-ci.xml_ file.
100+
If you use different commands to build your project, or you want to use a different target, you can specify those. For example, you may want to run the `verify` target that's configured in a `pom-ci.xml` file.
101101

102102
```yaml copy
103103
steps:
@@ -127,7 +127,7 @@ steps:
127127
run: mvn --batch-mode --update-snapshots verify
128128
```
129129

130-
This workflow will save the contents of your local Maven repository, located in the `.m2` directory of the runner's home directory. The cache key will be the hashed contents of _pom.xml_, so changes to _pom.xml_ will invalidate the cache.
130+
This workflow will save the contents of your local Maven repository, located in the `.m2` directory of the runner's home directory. The cache key will be the hashed contents of `pom.xml`, so changes to `pom.xml` will invalidate the cache.
131131

132132
## Packaging workflow data as artifacts
133133

content/actions/use-cases-and-examples/building-and-testing/building-and-testing-nodejs.md

+8-8
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ You can also cache dependencies to speed up your workflow. For more information,
154154

155155
### Example using npm
156156

157-
This example installs the versions in the _package-lock.json_ or _npm-shrinkwrap.json_ file and prevents updates to the lock file. Using `npm ci` is generally faster than running `npm install`. For more information, see [`npm ci`](https://docs.npmjs.com/cli/ci.html) and [Introducing `npm ci` for faster, more reliable builds](https://blog.npmjs.org/post/171556855892/introducing-npm-ci-for-faster-more-reliable).
157+
This example installs the versions in the `package-lock.json` or `npm-shrinkwrap.json` file and prevents updates to the lock file. Using `npm ci` is generally faster than running `npm install`. For more information, see [`npm ci`](https://docs.npmjs.com/cli/ci.html) and [Introducing `npm ci` for faster, more reliable builds](https://blog.npmjs.org/post/171556855892/introducing-npm-ci-for-faster-more-reliable).
158158

159159
```yaml copy
160160
steps:
@@ -167,7 +167,7 @@ steps:
167167
run: npm ci
168168
```
169169

170-
Using `npm install` installs the dependencies defined in the _package.json_ file. For more information, see [`npm install`](https://docs.npmjs.com/cli/install).
170+
Using `npm install` installs the dependencies defined in the `package.json` file. For more information, see [`npm install`](https://docs.npmjs.com/cli/install).
171171

172172
```yaml copy
173173
steps:
@@ -182,7 +182,7 @@ steps:
182182

183183
### Example using Yarn
184184

185-
This example installs the dependencies defined in the _yarn.lock_ file and prevents updates to the _yarn.lock_ file. For more information, see [`yarn install`](https://yarnpkg.com/en/docs/cli/install).
185+
This example installs the dependencies defined in the `yarn.lock` file and prevents updates to the `yarn.lock` file. For more information, see [`yarn install`](https://yarnpkg.com/en/docs/cli/install).
186186

187187
```yaml copy
188188
steps:
@@ -195,7 +195,7 @@ steps:
195195
run: yarn --frozen-lockfile
196196
```
197197

198-
Alternatively, you can install the dependencies defined in the _package.json_ file.
198+
Alternatively, you can install the dependencies defined in the `package.json` file.
199199

200200
```yaml copy
201201
steps:
@@ -214,9 +214,9 @@ steps:
214214

215215
To authenticate to your private registry, you'll need to store your npm authentication token as a secret. For example, create a repository secret called `NPM_TOKEN`. For more information, see [AUTOTITLE](/actions/security-guides/using-secrets-in-github-actions).
216216

217-
In the example below, the secret `NPM_TOKEN` stores the npm authentication token. The `setup-node` action configures the _.npmrc_ file to read the npm authentication token from the `NODE_AUTH_TOKEN` environment variable. When using the `setup-node` action to create an _.npmrc_ file, you must set the `NODE_AUTH_TOKEN` environment variable with the secret that contains your npm authentication token.
217+
In the example below, the secret `NPM_TOKEN` stores the npm authentication token. The `setup-node` action configures the `.npmrc` file to read the npm authentication token from the `NODE_AUTH_TOKEN` environment variable. When using the `setup-node` action to create an `.npmrc` file, you must set the `NODE_AUTH_TOKEN` environment variable with the secret that contains your npm authentication token.
218218

219-
Before installing dependencies, use the `setup-node` action to create the _.npmrc_ file. The action has two input parameters. The `node-version` parameter sets the Node.js version, and the `registry-url` parameter sets the default registry. If your package registry uses scopes, you must use the `scope` parameter. For more information, see [`npm-scope`](https://docs.npmjs.com/misc/scope).
219+
Before installing dependencies, use the `setup-node` action to create the `.npmrc` file. The action has two input parameters. The `node-version` parameter sets the Node.js version, and the `registry-url` parameter sets the default registry. If your package registry uses scopes, you must use the `scope` parameter. For more information, see [`npm-scope`](https://docs.npmjs.com/misc/scope).
220220

221221
```yaml copy
222222
steps:
@@ -234,7 +234,7 @@ steps:
234234
NODE_AUTH_TOKEN: {% raw %}${{ secrets.NPM_TOKEN }}{% endraw %}
235235
```
236236

237-
The example above creates an _.npmrc_ file with the following contents:
237+
The example above creates an `.npmrc` file with the following contents:
238238

239239
```shell
240240
//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}
@@ -296,7 +296,7 @@ If you have a custom requirement or need finer controls for caching, you can use
296296

297297
## Building and testing your code
298298

299-
You can use the same commands that you use locally to build and test your code. For example, if you run `npm run build` to run build steps defined in your _package.json_ file and `npm test` to run your test suite, you would add those commands in your workflow file.
299+
You can use the same commands that you use locally to build and test your code. For example, if you run `npm run build` to run build steps defined in your `package.json` file and `npm test` to run your test suite, you would add those commands in your workflow file.
300300

301301
```yaml copy
302302
steps:

content/actions/use-cases-and-examples/building-and-testing/building-and-testing-python.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ steps:
233233

234234
### Requirements file
235235

236-
After you update `pip`, a typical next step is to install dependencies from _requirements.txt_. For more information, see [pip](https://pip.pypa.io/en/stable/cli/pip_install/#example-requirements-file).
236+
After you update `pip`, a typical next step is to install dependencies from `requirements.txt`. For more information, see [pip](https://pip.pypa.io/en/stable/cli/pip_install/#example-requirements-file).
237237

238238
```yaml copy
239239
steps:

content/actions/use-cases-and-examples/building-and-testing/building-and-testing-ruby.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ steps:
192192

193193
{% endraw %}
194194

195-
This will configure bundler to install your gems to `vendor/cache`. For each successful run of your workflow, this folder will be cached by {% data variables.product.prodname_actions %} and re-downloaded for subsequent workflow runs. A hash of your gemfile.lock and the Ruby version are used as the cache key. If you install any new gems, or change a version, the cache will be invalidated and bundler will do a fresh install.
195+
This will configure bundler to install your gems to `vendor/cache`. For each successful run of your workflow, this folder will be cached by {% data variables.product.prodname_actions %} and re-downloaded for subsequent workflow runs. A hash of your `gemfile.lock` and the Ruby version are used as the cache key. If you install any new gems, or change a version, the cache will be invalidated and bundler will do a fresh install.
196196

197197
**Caching without setup-ruby**
198198

content/actions/writing-workflows/choosing-when-your-workflow-runs/triggering-a-workflow.md

+4-2
Original file line numberDiff line numberDiff line change
@@ -294,15 +294,17 @@ jobs:
294294
runs-on: ubuntu-latest
295295
steps:
296296
- name: build
297-
echo 'building'
297+
run: |
298+
echo 'building'
298299
299300
publish:
300301
needs: [build]
301302
runs-on: ubuntu-latest
302303
environment: production
303304
steps:
304305
- name: publish
305-
echo 'publishing'
306+
run: |
307+
echo 'publishing'
306308
```
307309

308310
> [!NOTE]
+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
You can use the `setup-node` action to create a local _.npmrc_ file on the runner that configures the default registry and scope. The `setup-node` action also accepts an authentication token as input, used to access private registries or publish node packages. For more information, see [`setup-node`](https://github.com/actions/setup-node/).
1+
You can use the `setup-node` action to create a local `.npmrc` file on the runner that configures the default registry and scope. The `setup-node` action also accepts an authentication token as input, used to access private registries or publish node packages. For more information, see [`setup-node`](https://github.com/actions/setup-node/).

0 commit comments

Comments
 (0)