Skip to content

Commit

Permalink
Merge pull request screwdriver-cd-test#7 from screwdriver-cd-test/tky…
Browse files Browse the repository at this point in the history
…i-patch-1

fix: Use new workflow with requires keyword
  • Loading branch information
minzcmu authored Nov 3, 2017
2 parents 7b92a5f + 78af9f7 commit 9af92ba
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions screwdriver.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,4 @@
---
# Workflow list definition
# This list describes the order that the Jobs execute. The "main" Job is always
# executed first, followed in order of the Jobs listed in this Workflow block.
workflow:
# We define the workflow where the "publish" Job is started after the "main" Job.
- publish


# Shared definition block
# This is where you would define any attributes that all your jobs will
# inherit.
Expand All @@ -22,6 +14,13 @@ jobs:
# We explicitly define "main" in our configuration so that it does what we want
# it to do.
main:
# Requires is a single job name or array of job names that will trigger the job to run.
# Jobs defined with "requires: ~pr" are started by pull-request events.
# Jobs defined with "requires: ~commit" are started by push events.
# Jobs defined with "requires: ~sd@123:main" are started by job "main" from pipeline "123".
# Jobs defined with "requires: main" are started after "main" is done.
# Jobs defined with "requires: [deploy-west, deploy-east] are started after "deploy-west" and "deploy-east" are both done running successfully.
requires: [~pr, ~commit]
# Steps is the ordered list of commands to execute.
# Each step takes the form "step_name: command_to_run". The "step_name" is a
# convenient label to reference it by. The "command_to_run" is the single
Expand All @@ -36,6 +35,7 @@ jobs:
# We define another Job called "publish". In this stage of the pipeline, we intend
# on publishing our package to the NPM Registry.
publish:
requires: main
steps:
# "set_access" is the first step that is executed. We want the community to use
# our package, so we enable publicly accessible
Expand Down

0 comments on commit 9af92ba

Please sign in to comment.