mirror of https://github.com/actions/setup-go
Compare commits
3 Commits
d4afbde334
...
09348c077e
Author | SHA1 | Date |
---|---|---|
Masahiro Furudate | 09348c077e | |
Masahiro Furudate | cdcb360436 | |
Masahiro Furudate | 3fbd947386 |
15
README.md
15
README.md
|
@ -70,9 +70,10 @@ steps:
|
|||
>
|
||||
> ```yaml
|
||||
> go-version: '1.20'
|
||||
> ```
|
||||
> ```
|
||||
>
|
||||
> The recommendation is based on the YAML parser's behavior, which interprets non-wrapped values as numbers and, in the case of version 1.20, trims it down to 1.2, which may not be very obvious.
|
||||
|
||||
Matching an unstable pre-release:
|
||||
|
||||
```yaml
|
||||
|
@ -190,11 +191,13 @@ steps:
|
|||
|
||||
## Getting go version from the go.mod file
|
||||
|
||||
The `go-version-file` input accepts a path to a `go.mod` file or a `go.work` file that contains the version of Go to be
|
||||
used by a project. As the `go.mod` file contains only major and minor (e.g. 1.18) tags, the action will search for the
|
||||
latest available patch version sequentially in the runner's directory with the cached tools, in
|
||||
the [versions-manifest.json](https://github.com/actions/go-versions/blob/main/versions-manifest.json) file or at the go
|
||||
servers.
|
||||
The `go-version-file` input accepts a path to a `go.mod` file or a `go.work` file that contains the version of Go to be used by a project.
|
||||
|
||||
The `go` directive in `go.mod` can specify a patch version or omit it altogether (e.g., `go 1.22.0` or `go 1.22`).
|
||||
If a patch version is specified, that specific patch version will be used.
|
||||
If no patch version is specified, it will search for the latest available patch version in the cache,
|
||||
[versions-manifest.json](https://github.com/actions/go-versions/blob/main/versions-manifest.json), and the
|
||||
[official Go language website](https://golang.org/dl/?mode=json&include=all), in that order.
|
||||
|
||||
If both the `go-version` and the `go-version-file` inputs are provided then the `go-version` input is used.
|
||||
> The action will search for the `go.mod` file relative to the repository root
|
||||
|
|
|
@ -6,13 +6,13 @@ We have prepared a short guide so that the process of making your contribution i
|
|||
|
||||
## How can I contribute...
|
||||
|
||||
* [Contribute Documentation:green_book:](#contribute-documentation)
|
||||
* [Contribute Documentation :green_book:](#contribute-documentation)
|
||||
|
||||
* [Contribute Code :computer:](#contribute-code)
|
||||
|
||||
* [Provide Support on Issues:pencil:](#provide-support-on-issues)
|
||||
* [Provide Support on Issues :pencil:](#provide-support-on-issues)
|
||||
|
||||
* [Review Pull Requests:mag:](#review-pull-requests)
|
||||
* [Review Pull Requests :mag:](#review-pull-requests)
|
||||
|
||||
## Contribute documentation
|
||||
|
||||
|
@ -113,4 +113,4 @@ Another great way to contribute is pull request reviews. Please, be extra kind:
|
|||
- Make sure you're familiar with the code or documentation is updated, unless it's a minor change (spellchecking, minor formatting, etc.)
|
||||
- Review changes using the GitHub functionality. You can ask a clarifying question, point out an error or suggest an alternative.
|
||||
> Note: You may ask for minor changes - "nitpicks", but consider whether they are real blockers to merging or not
|
||||
- Submit your review, which may include comments, an approval, or a changes request
|
||||
- Submit your review, which may include comments, an approval, or a changes request
|
||||
|
|
110
package.json
110
package.json
|
@ -1,55 +1,55 @@
|
|||
{
|
||||
"name": "setup-go",
|
||||
"version": "5.0.0",
|
||||
"private": true,
|
||||
"description": "setup go action",
|
||||
"main": "lib/setup-go.js",
|
||||
"scripts": {
|
||||
"build": "tsc && ncc build -o dist/setup src/setup-go.ts && ncc build -o dist/cache-save src/cache-save.ts",
|
||||
"format": "prettier --no-error-on-unmatched-pattern --config ./.prettierrc.js --write \"**/*.{ts,yml,yaml}\"",
|
||||
"format-check": "prettier --no-error-on-unmatched-pattern --config ./.prettierrc.js --check \"**/*.{ts,yml,yaml}\"",
|
||||
"lint": "eslint --config ./.eslintrc.js \"**/*.ts\"",
|
||||
"lint:fix": "eslint --config ./.eslintrc.js \"**/*.ts\" --fix",
|
||||
"test": "jest --coverage",
|
||||
"pre-checkin": "npm run format && npm run lint:fix && npm run build && npm test"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/actions/setup-go.git"
|
||||
},
|
||||
"keywords": [
|
||||
"actions",
|
||||
"go",
|
||||
"setup"
|
||||
],
|
||||
"author": "GitHub",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@actions/cache": "^3.2.4",
|
||||
"@actions/core": "^1.10.0",
|
||||
"@actions/exec": "^1.1.0",
|
||||
"@actions/glob": "^0.4.0",
|
||||
"@actions/http-client": "^2.2.1",
|
||||
"@actions/io": "^1.0.2",
|
||||
"@actions/tool-cache": "^2.0.1",
|
||||
"semver": "^7.6.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/jest": "^29.5.12",
|
||||
"@types/node": "^20.11.28",
|
||||
"@types/semver": "^7.5.8",
|
||||
"@typescript-eslint/eslint-plugin": "^5.54.0",
|
||||
"@typescript-eslint/parser": "^5.54.0",
|
||||
"@vercel/ncc": "^0.38.1",
|
||||
"eslint": "^8.57.0",
|
||||
"eslint-config-prettier": "^8.6.0",
|
||||
"eslint-plugin-jest": "^27.9.0",
|
||||
"eslint-plugin-node": "^11.1.0",
|
||||
"jest": "^29.7.0",
|
||||
"jest-circus": "^29.7.0",
|
||||
"nock": "^10.0.6",
|
||||
"prettier": "^2.8.4",
|
||||
"ts-jest": "^29.1.2",
|
||||
"typescript": "^5.4.2"
|
||||
}
|
||||
}
|
||||
{
|
||||
"name": "setup-go",
|
||||
"version": "5.0.0",
|
||||
"private": true,
|
||||
"description": "setup go action",
|
||||
"main": "lib/setup-go.js",
|
||||
"scripts": {
|
||||
"build": "tsc && ncc build -o dist/setup src/setup-go.ts && ncc build -o dist/cache-save src/cache-save.ts",
|
||||
"format": "prettier --no-error-on-unmatched-pattern --config ./.prettierrc.js --write \"**/*.{ts,yml,yaml}\"",
|
||||
"format-check": "prettier --no-error-on-unmatched-pattern --config ./.prettierrc.js --check \"**/*.{ts,yml,yaml}\"",
|
||||
"lint": "eslint --config ./.eslintrc.js \"**/*.ts\"",
|
||||
"lint:fix": "eslint --config ./.eslintrc.js \"**/*.ts\" --fix",
|
||||
"test": "jest --coverage",
|
||||
"pre-checkin": "npm run format && npm run lint:fix && npm run build && npm test"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/actions/setup-go.git"
|
||||
},
|
||||
"keywords": [
|
||||
"actions",
|
||||
"go",
|
||||
"setup"
|
||||
],
|
||||
"author": "GitHub",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@actions/cache": "^3.2.4",
|
||||
"@actions/core": "^1.10.0",
|
||||
"@actions/exec": "^1.1.0",
|
||||
"@actions/glob": "^0.4.0",
|
||||
"@actions/http-client": "^2.2.1",
|
||||
"@actions/io": "^1.0.2",
|
||||
"@actions/tool-cache": "^2.0.1",
|
||||
"semver": "^7.6.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/jest": "^29.5.12",
|
||||
"@types/node": "^20.11.28",
|
||||
"@types/semver": "^7.5.8",
|
||||
"@typescript-eslint/eslint-plugin": "^5.54.0",
|
||||
"@typescript-eslint/parser": "^5.54.0",
|
||||
"@vercel/ncc": "^0.38.1",
|
||||
"eslint": "^8.57.0",
|
||||
"eslint-config-prettier": "^8.6.0",
|
||||
"eslint-plugin-jest": "^27.9.0",
|
||||
"eslint-plugin-node": "^11.1.0",
|
||||
"jest": "^29.7.0",
|
||||
"jest-circus": "^29.7.0",
|
||||
"nock": "^10.0.6",
|
||||
"prettier": "^2.8.4",
|
||||
"ts-jest": "^29.1.2",
|
||||
"typescript": "^5.4.2"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue