-
Notifications
You must be signed in to change notification settings - Fork 378
Expand file tree
/
Copy pathconfig.yml
More file actions
115 lines (108 loc) · 2.95 KB
/
config.yml
File metadata and controls
115 lines (108 loc) · 2.95 KB
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
version: 2.1
setup: true
on_main_or_tag_filter: &on_main_or_tag_filter
filters:
branches:
only: main
tags:
only: /^v\d+\.\d+\.\d+/
on_tag_filter: &on_tag_filter
filters:
branches:
ignore: /.*/
tags:
only: /^v\d+\.\d+\.\d+/
orbs:
path-filtering: circleci/path-filtering@1.2.0
jobs:
publish:
docker:
- image: cimg/python:3.10
resource_class: small
steps:
- checkout
- attach_workspace:
at: web/client
- run:
name: Publish Python package
command: make publish
- run:
name: Update pypirc
command: ./.circleci/update-pypirc.sh
- run:
name: Publish Python Tests package
command: unset TWINE_USERNAME TWINE_PASSWORD && make publish-tests
gh-release:
docker:
- image: cimg/node:20.19.0
resource_class: small
steps:
- run:
name: Create release on GitHub
command: |
GITHUB_TOKEN="$GITHUB_TOKEN" \
TARGET_TAG="$CIRCLE_TAG" \
REPO_OWNER="$CIRCLE_PROJECT_USERNAME" \
REPO_NAME="$CIRCLE_PROJECT_REPONAME" \
CONTINUE_ON_ERROR="false" \
npx https://github.com/TobikoData/circleci-gh-conventional-release
ui-build:
docker:
- image: cimg/node:20.19.0
resource_class: medium
steps:
- checkout
- run:
name: Install Dependencies
command: |
pnpm install
- run:
name: Build UI
command: pnpm --prefix web/client run build
- persist_to_workspace:
root: web/client
paths:
- dist
trigger_private_renovate:
docker:
- image: cimg/base:2021.11
resource_class: small
steps:
- run:
name: Trigger private renovate
command: |
curl --request POST \
--url $TOBIKO_PRIVATE_CIRCLECI_URL \
--header "Circle-Token: $TOBIKO_PRIVATE_CIRCLECI_KEY" \
--header "content-type: application/json" \
--data '{
"branch":"main",
"parameters":{
"run_main_pr":false,
"run_sqlmesh_commit":false,
"run_renovate":true
}
}'
workflows:
setup-workflow:
jobs:
- path-filtering/filter:
mapping: |
web/client/.* client true
(sqlmesh|tests|examples|web/server)/.* python true
pytest.ini|setup.cfg|setup.py|pyproject.toml python true
\.circleci/.*|Makefile|\.pre-commit-config\.yaml common true
vscode/extensions/.* vscode true
tag: "3.9"
- gh-release:
<<: *on_tag_filter
- ui-build:
<<: *on_main_or_tag_filter
- publish:
<<: *on_main_or_tag_filter
requires:
- ui-build
- trigger_private_renovate:
<<: *on_tag_filter
requires:
- publish