Skip to content

Commit

Permalink
fix: add version (#93)
Browse files Browse the repository at this point in the history
  • Loading branch information
sethyates authored Aug 16, 2023
1 parent 95363bc commit 39d9ab5
Show file tree
Hide file tree
Showing 7 changed files with 5,532 additions and 3,313 deletions.
20 changes: 11 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,17 @@ To use the GitHub Action, add the following to your job:
### Inputs
| Name | Default | Description |
|-------------|-----------------|------------------------------------------------------------|
| `package` | `./cmd/*` | the package to build |
| `platforms` | native platform | comma-separated list of platforms to build |
| `tags` | N/A | comma-separated list of build tags to pass to go compiler |
| `buildvcs` | `auto` | whether to stamp binaries with version control information |
| `buildmode` | `default` | which kind of object file is to be built |
| `trimpath` | `true` | remove all file system paths from the resulting executable |
| Name | Default | Description |
|--------------------|-----------------|---------------------------------------------------------------|
| `package` | `./cmd/*` | the package to build |
| `platforms` | native platform | comma-separated list of platforms to build |
| `tags` | N/A | comma-separated list of build tags to pass to go compiler |
| `buildvcs` | `auto` | whether to stamp binaries with version control information |
| `buildmode` | `default` | which kind of object file is to be built |
| `trimpath` | `true` | remove all file system paths from the resulting executable |
| `version-package` | `main` | go package to write version to |
| `version-variable` | `Version` | the variable name to write the version to |
| `version` | N/A | version to write to the specified package/variable (optional) |

### Outputs

Expand Down Expand Up @@ -54,4 +57,3 @@ jobs:
## License

The scripts and documentation in this project are released under the [MIT License](LICENSE).

11 changes: 11 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,17 @@ inputs:
required: false
description: 'value of GOSUMDB'
default: ''
version-package:
required: false
description: 'go package to write version to'
default: 'main'
version-variable:
required: false
description: 'the variable name to write the version to'
default: 'Version'
version:
required: false
description: 'version to write'
outputs:
outputs:
description: 'list of output binaries'
Expand Down
Loading

0 comments on commit 39d9ab5

Please sign in to comment.