This new version requires unique artifact names. We achieve this by
omitting the downloaded artifact name, which causes the action to
download all artifacts from the run.
Signed-off-by: Nic Cope <nicc@rk0n.org>
The CI workflow uses a semver (e.g. v1.0.0) when you run it using the
workflow_dispatch trigger and supply one explicitly. This is how you
'release' a function.
Today when the workflow runs for a PR or regular main branch build we
default to v0.0.0-<git-short-sha>. This is a very simple way to tag
development builds with no user input required. It's handy that the
resulting package can be correlated to the git commit that produced it
using the git SHA.
A major flaw of this implementation is that newer SHAs do not sort above
older SHAs when treated as semantic versions.
This commit switches us to a simple approximation of the Go
pseudoversions you would see in a go.mod file, as described by
https://go.dev/ref/mod#pseudo-versions. These versions include the git
commit time before the SHA, so newer commits will be considered newer
versions when processing the semver. We also switch to using the first
12 characters of the SHA. This reduces the risk of collision, and makes
us match exactly Go's pseudoversion implementation.
Signed-off-by: Nic Cope <nicc@rk0n.org>
This is the c/c linter config. The one exception is (hopefully) less
fussy sorting of crossplane related imports. It just wants all
crossplane org things in one block, and all contrib org things in
another block. This means folks won't need to update the linter config
when they use the template (e.g. to update the GCI prefixes).
Signed-off-by: Nic Cope <nicc@rk0n.org>
The CI workflow uses a semver (e.g. v1.0.0) when you run it using the
workflow_dispatch trigger and supply one explicitly. This is how you
'release' a function.
Today when the workflow runs for a PR or regular main branch build we
default to v0.0.0-<git-short-sha>. This is a very simple way to tag
development builds with no user input required. It's handy that the
resulting package can be correlated to the git commit that produced it
using the git SHA.
A major flaw of this implementation is that newer SHAs do not sort above
older SHAs when treated as semantic versions.
This commit switches us to a simple approximation of the Go
pseudoversions you would see in a go.mod file, as described by
https://go.dev/ref/mod#pseudo-versions. These versions include the git
commit time before the SHA, so newer commits will be considered newer
versions when processing the semver. We also switch to using the first
12 characters of the SHA. This reduces the risk of collision, and makes
us match exactly Go's pseudoversion implementation.
Signed-off-by: Nic Cope <nicc@rk0n.org>
This is mostly useful to prompt function authors to have an example
directory, rather than to exercise the template code.
Signed-off-by: Nic Cope <nicc@rk0n.org>
Instead mostly link to the new guide, which has all the information this
used to have either directly or by links to the other functions docs.
Signed-off-by: Nic Cope <nicc@rk0n.org>