blob: 4bfa3f02363a09a754ba54c470717a76aa4098bc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
when:
branch:
exclude: pages
pipeline:
test:
image: node:lts
commands:
- npm install
- npm test
audit:
image: node:lts
commands:
- npm audit
docs:
image: node:lts
commands:
- npm run docs
publish-npm:
image: node:lts
secrets: [ npmtoken ]
commands:
- npm config set -- '//registry.npmjs.org/:_authToken' "${NPMTOKEN}"
- npm publish
when:
# Push new version when version tag is created
event: tag
tag: v*
publish-pages:
image: rust:latest
secrets: [ cbtoken ]
commands:
- git config --global user.email "woodpecker@worthe-it.co.za"
- git config --global user.name "CI Builder"
- git clone -b pages https://$CBTOKEN@codeberg.org/$CI_REPO.git pages
- cp -r dist/docs "pages/$CI_COMMIT_TAG"
- cd pages
- cargo run
- git add --all
- git commit -m "Woodpecker CI Generated Docs"
- git push
when:
# Push new version when version tag is created
event: tag
tag: v*
|