-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy path.gitlab-ci.yml
51 lines (46 loc) · 1.16 KB
/
.gitlab-ci.yml
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
49
50
51
stages:
- Build
- QA
- Test
- Release
build:
stage: Build
artifacts:
name: '$CI_PIPELINE_ID-$CI_COMMIT_SHA'
paths:
- node_modules/
- dist/
expire_in: 2 days
script:
- pnpm install -d --frozen-lockfile
- pnpm build
eslint:
stage: QA
allow_failure: true
script:
- pnpm run eslint
prettier:
stage: QA
allow_failure: true
script:
- npx prettier --check .
chrome_stable:
stage: Test
image: flat/chrome-stable
script:
- node -v
- google-chrome --version
- pnpm test
release_s3:
stage: Release
tags: ['docker-with-flat-configs']
only:
- tags
script:
- GIT_TAG=$(git describe --tags)
# compat with old rollup build and public UMD urls
- cp dist/flat-embed.umd.js dist/embed.min.js
# only upload types to npm packages, not needed on cdn
- find dist -name "*.d.ts" -delete
- s3cmd -c /root/.s3cfg.prod-static sync --no-mime-magic --guess-mime-type --no-preserve dist/ s3://prod.flat-cdn.com/embed-js/${GIT_TAG}/
- s3cmd -c /root/.s3cfg.prod-static-wasabi sync --acl-public --no-mime-magic --guess-mime-type --no-preserve dist/ s3://prod.flat-cdn.com/embed-js/${GIT_TAG}/