Skip to content

Commit b9a874c

Browse files
Revert "Update workflows.md"
1 parent 8d92e8e commit b9a874c

File tree

1 file changed

+8
-14
lines changed

1 file changed

+8
-14
lines changed

jekyll/_cci2/workflows.md

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ With workflows, you can:
2525
- Fan-out to run multiple jobs in parallel for efficient version testing.
2626
- Fan-in to quickly deploy to multiple platforms.
2727

28-
For example, if only one job in a workflow fails, you will know it is failing in real-time. Instead of wasting time waiting for the entire build to fail and re-running the entire job set, you can rerun *just the failed job*.
28+
For example, if only one job in a workflow fails, you will know it is failing in real-time. Instead of wasting time waiting for the entire build to fail and rerunning the entire job set, you can rerun *just the failed job*.
2929

3030
### States
3131
{:.no_toc}
@@ -44,7 +44,7 @@ Workflows may appear with one of the following states:
4444
### Limitations
4545
{:.no_toc}
4646

47-
Projects that have pipelines enabled during pipeline processing may use the CircleCI API to trigger workflows. Projects that do not enable pipelines will run as if the workflows did not exist when triggered by the API. **Note:** Pipelines without workflows require a `build` job.
47+
Projects that have pipelines enabled may use the CircleCI API to trigger workflows. Projects that do not enable pipelines will run as if the workflows did not exist when triggered by the API. **Note:** Builds without workflows require a `build` job.
4848

4949
Refer to the [Workflows]({{ site.baseurl }}/2.0/faq) section of the FAQ for additional information and limitations.
5050

@@ -90,7 +90,6 @@ The following example shows a workflow with four sequential jobs. The jobs run a
9090
The following `config.yml` snippet is an example of a workflow configured for sequential job execution:
9191

9292
```yaml
93-
version: 2.1
9493
workflows:
9594
version: 2
9695
build-test-and-deploy:
@@ -121,7 +120,6 @@ The illustrated example workflow runs a common build job, then fans-out to run a
121120
The following `config.yml` snippet is an example of a workflow configured for fan-out/fan-in job execution:
122121

123122
```yaml
124-
version: 2.1
125123
workflows:
126124
version: 2
127125
build_accept_deploy:
@@ -152,11 +150,12 @@ See the [Sample Fan-in/Fan-out Workflow config](https://github.com/CircleCI-Publ
152150

153151
## Holding a Workflow for a Manual Approval
154152

155-
Workflows can be configured to wait for manual approval of a job before continuing to the next job. Anyone who has push access to the repository can click the Approval button to continue the workflow. To do this, add a job to the `jobs` list with the
153+
Workflows can be configured to wait for manual approval of a job before
154+
continuing to the next job. Anyone who has push access to the repository can click the Approval button to continue the workflow.
155+
To do this, add a job to the `jobs` list with the
156156
key `type: approval`. Let's look at a commented config example.
157157

158158
```yaml
159-
version: 2.1
160159
# ...
161160
# << Your config for the build, test1, test2, and deploy jobs >>
162161
# ...
@@ -188,7 +187,8 @@ The outcome of the above example is that the `deploy:` job will not run until yo
188187
Some things to keep in mind when using manual approval in a workflow:
189188

190189
- `approval` is a special job type that is **only** available to jobs under the `workflow` key
191-
- The `hold` job must be a unique name not used by any other job; that is, your custom configured jobs, such as `build` or `test1` in the example above wouldn't be given a `type: approval` key.
190+
- The `hold` job must be a unique name not used by any other job.
191+
- that is, your custom configured jobs, such as `build` or `test1` in the example above wouldn't be given a `type: approval` key.
192192
- The name of the job to hold is arbitrary - it could be `wait` or `pause`, for example, as long as the job has a `type: approval` key in it.
193193
- All jobs that are to run after a manually approved job _must_ `require:` the name of that job. Refer to the `deploy:` job in the above example.
194194
- Jobs run in the order defined until the workflow processes a job with the `type: approval` key followed by a job on which it depends.
@@ -218,7 +218,6 @@ By default, a workflow is triggered on every `git push`. To trigger a workflow o
218218
In the example below, the `nightly` workflow is configured to run every day at 12:00am UTC. The `cron` key is specified using POSIX `crontab` syntax, see the [crontab man page](https://www.unix.com/man-page/POSIX/1posix/crontab/) for `cron` syntax basics. The workflow will be run on the `master` and `beta` branches.
219219

220220
```yaml
221-
version: 2.1
222221
workflows:
223222
version: 2
224223
commit:
@@ -268,7 +267,6 @@ The following example shows a workflow with four sequential jobs that use a cont
268267
The following `config.yml` snippet is an example of a sequential job workflow configured to use the resources defined in the `org-global` context:
269268

270269
```yaml
271-
version: 2.1
272270
workflows:
273271
version: 2
274272
build-test-and-deploy:
@@ -299,7 +297,6 @@ The following example shows a workflow configured with jobs on three branches: D
299297
The following `config.yml` snippet is an example of a workflow configured for branch-level job execution:
300298

301299
```yaml
302-
version: 2.1
303300
workflows:
304301
version: 2
305302
dev_stage_pre-prod:
@@ -336,7 +333,6 @@ In the example below, two workflows are defined:
336333
- `tagged-build` runs `build` for all branches **and** all tags starting with `v`.
337334

338335
```yaml
339-
version: 2.1
340336
workflows:
341337
version: 2
342338
untagged-build:
@@ -356,7 +352,6 @@ In the example below, two jobs are defined within the `build-n-deploy` workflow:
356352
- The `deploy` job runs for no branches and only for tags starting with 'v'.
357353

358354
```yaml
359-
version: 2.1
360355
workflows:
361356
version: 2
362357
build-n-deploy:
@@ -382,7 +377,6 @@ In the example below, three jobs are defined with the `build-test-deploy` workfl
382377
- The `deploy` job runs for no branches and only tags starting with 'config-test'.
383378

384379
```yaml
385-
version: 2.1
386380
workflows:
387381
version: 2
388382
build-test-deploy:
@@ -517,7 +511,7 @@ It has been observed that in some cases, a failure happens before the workflow r
517511

518512
When creating or modifying workflow configuration, if you don't see new jobs, you may have a configuration error in `config.yml`.
519513

520-
Sometimes, if you do not see your workflows triggering, a configuration error is preventing the workflow from starting. As a result, the workflow does not start any jobs.
514+
Oftentimes if you do not see your workflows triggering, a configuration error is preventing the workflow from starting. As a result, the workflow does not start any jobs.
521515

522516
When setting up workflows, you currently have to check your Workflows page of the CircleCI app (*not* the Job page) to view the configuration errors.
523517

0 commit comments

Comments
 (0)