Skip to content

Commit 15c4e99

Browse files
committed
feat: add release not processing
1 parent afa2b36 commit 15c4e99

File tree

2 files changed

+19
-4
lines changed

2 files changed

+19
-4
lines changed

.drone.star

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
OC_CI_NODEJS = "owncloudci/nodejs:18"
22
OC_CI_BAZEL_BUILDIFIER = "owncloudci/bazel-buildifier"
33
OC_CI_ALPINE = "owncloudci/alpine:latest"
4+
OC_CI_UBUNTU = "owncloud/ubuntu:latest"
45

56
PLUGINS_DOCKER = "plugins/docker:20.14"
67
PLUGINS_GITHUB_RELEASE = "plugins/github-release:1"
@@ -214,7 +215,7 @@ def publishSteps(ctx):
214215
"sha256",
215216
],
216217
"title": "%s %s" % (app, version),
217-
"note": ".release_note",
218+
"note": "release_note",
218219
"overwrite": True,
219220
},
220221
"when": {
@@ -245,10 +246,24 @@ def appBuilds(ctx):
245246
],
246247
})
247248

249+
app_build_steps.append({
250+
"name": "prepare-release-%s" % app,
251+
"image": OC_CI_UBUNTU,
252+
"depends_on": ["build-%s" % app],
253+
"commands": [
254+
"echo '{\"Name\": \"%s\",\"Version\": \"%s\"}' | gomplate -f .release_note -c Product=stdin:///product.json | tee release_note" % (release_app, release_version),
255+
],
256+
"when": {
257+
"ref": [
258+
"refs/tags/**",
259+
],
260+
},
261+
})
262+
248263
app_build_steps.append({
249264
"name": "package-%s" % app,
250265
"image": OC_CI_ALPINE,
251-
"depends_on": ["build-%s" % app],
266+
"depends_on": ["prepare-release-%s" % app],
252267
"commands": [
253268
"apk add zip",
254269
"cd assets/extensions",

.release_note

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
{{ .Product }}-{{ .Version }}
1+
{{ .Product.Name }}-{{ .Product.Version }}
22

33
## How to use
4-
Download the attached release artifact "{{ .Product }}-{{ .Version }}.zip" and extract it to your oCIS apps folder.
4+
Download the attached release artifact "{{ .Product.Name }}-{{ .Product.Version }}.zip" and extract it to your oCIS apps folder.
55
Please refer to [our documentation](https://owncloud.dev/services/web/#loading-applications) for more information.

0 commit comments

Comments
 (0)