Skip to content

vitalinfo/circleci-cancel-draft

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

circleci-cancel-draft

CircleCI runs build for Draft PR.

This docker image supports cancel build if PR in the Drfat status or has Draft label.

version: 2
jobs:
  cancel_draft_build:
    parallelism: 1
    docker:
      - image: vitalinfo/circleci-cancel-draft
        environment:
          CIRCLECI_TOKEN: ZZZZZZZZZZZ
          GITHUB_TOKEN:   XXXXXXXXXXX
    steps:
      - run: cancel-draft-build

workflows:
  version: 2
  tests:
    jobs:
      - cancel_draft_build
      - ... # other build steps

Deployment

$ docker build . -t vitalinfo/circleci-cancel-draft && docker push vitalinfo/circleci-cancel-draft

Tokens

GitHub Token

  1. Open New personal access token (classic)
  2. Set Note
  3. Choose Expiration
  4. Select workflow scope readme.png
  5. Click Generate token

CircleCI Token

  1. Open Personal API Tokens
  2. Click Create New API Token
  3. Set Token Name
  4. Click Add API Token

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published