We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d959e9a commit a057ce5Copy full SHA for a057ce5
.gitlab-ci.yml
@@ -0,0 +1,16 @@
1
+optic-default-branch-push:
2
+ image: node:latest
3
+ rules:
4
+ - if: $CI_PIPELINE_SOURCE == "push" && OPTIC_TOKEN && $CI_COMMIT_REF_NAME == $CI_DEFAULT_BRANCH
5
+ script:
6
+ - npm install -g @useoptic/optic
7
+ - optic run
8
+
9
+optic-merge-request:
10
11
12
+ - if: $CI_PIPELINE_SOURCE == "merge_request_event" && $OPTIC_TOKEN
13
14
15
+ - export OPTIC_RESULT=0; optic run || export OPTIC_RESULT=$?
16
+ - if [ $OPTIC_RESULT -ne 0 ]; then exit 1; fi;
0 commit comments