File tree Expand file tree Collapse file tree 2 files changed +24
-6
lines changed Expand file tree Collapse file tree 2 files changed +24
-6
lines changed Original file line number Diff line number Diff line change @@ -100,16 +100,24 @@ jobs:
100
100
- ./package.json
101
101
# - jobstatus
102
102
103
- publish :
103
+ publish-dev :
104
+ executor : build-executor
105
+ steps :
106
+ - run :
107
+ name : Publish development pacts to broker
108
+ command : npm run pact:publish-dev
109
+ # - jobstatus
110
+
111
+ publish-prod :
104
112
executor : build-executor
105
113
steps :
106
114
- attach_workspace :
107
115
at : /tmp/workspace
108
116
- setup_environment :
109
117
version_path : /tmp/workspace
110
118
- run :
111
- name : Publish pacts to broker
112
- command : npm run pact:publish
119
+ name : Publish production pacts to broker
120
+ command : cd /tmp/workspace && npm run pact:publish-prod
113
121
- run :
114
122
name : Publish package to NPM
115
123
command : cd /tmp/workspace && npm publish
@@ -134,7 +142,16 @@ workflows:
134
142
build-and-deploy :
135
143
jobs :
136
144
- build_test
137
- - publish :
145
+ - publish-dev :
146
+ context :
147
+ - org-global
148
+ - w3w-pact
149
+ requires :
150
+ - build_test
151
+ filters :
152
+ branches :
153
+ ignore : master
154
+ - publish-prod :
138
155
context :
139
156
- org-global
140
157
- w3w-pact
@@ -145,5 +162,5 @@ workflows:
145
162
only : master
146
163
- tag :
147
164
requires :
148
- - publish
165
+ - publish-prod
149
166
Original file line number Diff line number Diff line change 20
20
"pact_do_not_track" : true
21
21
},
22
22
"scripts" : {
23
- "pact:publish" : " pact-broker publish pacts --consumer-app-version=\" $npm_package_version-$(git rev-parse --short HEAD)\" --auto-detect-version-properties --broker-base-url=${PACT_BROKER_BASE_URL}" ,
23
+ "pact:publish-dev" : " pact-broker publish pacts --consumer-app-version=\" $npm_package_version-$(git rev-parse --short HEAD)\" --auto-detect-version-properties --broker-base-url=${PACT_BROKER_BASE_URL}" ,
24
+ "pact:publish-prod" : " pact-broker publish pacts --consumer-app-version=\" $npm_package_version\" --auto-detect-version-properties --broker-base-url=${PACT_BROKER_BASE_URL}" ,
24
25
"test" : " jest" ,
25
26
"test:watch" : " jest --watch" ,
26
27
"coverage" : " jest --coverage" ,
You can’t perform that action at this time.
0 commit comments