Skip to content

Commit 606db9b

Browse files
authored
Update reusing-config.md
Fixed some formatting errors in content
1 parent f07f11e commit 606db9b

File tree

1 file changed

+31
-4
lines changed

1 file changed

+31
-4
lines changed

jekyll/_cci2/reusing-config.md

Lines changed: 31 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -485,7 +485,10 @@ commands:
485485
Use an `executor` parameter type to allow the invoker of a job to decide what
486486
executor it will run on.
487487

488-
```yaml
488+
```
489+
{% raw %}
490+
491+
yaml
489492
version: 2.1
490493
executors:
491494
xenial:
@@ -519,14 +522,19 @@ workflows:
519522
e:
520523
name: xenial
521524
some-value: foobar
525+
526+
{% endraw %}
522527
```
523528
524529
#### Steps
525530
{:.no_toc}
526531
527532
Steps are used when you have a job or command that needs to mix predefined and user-defined steps. When passed in to a command or job invocation, the steps passed as parameters are always defined as a sequence, even if only one step is provided.
528533
529-
```yaml
534+
```
535+
{% raw %}
536+
537+
yaml
530538
commands:
531539
run-tests:
532540
parameters:
@@ -538,11 +546,17 @@ commands:
538546
- run: make deps
539547
- steps: << parameters.after-deps >>
540548
- run: make test
549+
550+
{% endraw %}
551+
541552
```
542553
543554
The following example demonstrates that steps passed as parameters are given as the value of a `steps` declaration under the job's `steps`.
544555
545-
```yaml
556+
```
557+
{% raw %}
558+
559+
yaml
546560
jobs:
547561
build:
548562
machine: true
@@ -551,22 +565,33 @@ jobs:
551565
after-deps:
552566
- run: echo "The dependencies are installed"
553567
- run: echo "And now I'm going to run the tests"
568+
569+
{% endraw %}
570+
554571
```
555572
556573
The above will resolve to the following:
557574
558-
```yaml
575+
```
576+
{% raw %}
577+
578+
yaml
559579
steps:
560580
- run: make deps
561581
- run: echo "The dependencies are installed"
562582
- run: echo "And now I'm going to run the tests"
563583
- run: make test
584+
585+
{% endraw %}
586+
564587
```
565588
#### Environment Variable Name
566589
567590
The environment variable name (``env_var_name``) parameter is a string that must match a POSIX_NAME regexp (e.g. no spaces or special characters) and is a more meaningful parameter type that enables additional checks to be performed. An example of this parameter is shown below.
568591
569592
```
593+
{% raw %}
594+
570595
version: 2
571596
jobs:
572597
build:
@@ -611,6 +636,8 @@ workflows:
611636
access-key: FOO_BAR
612637
secret-key: BIN_BAZ
613638
command: ls s3://some/where
639+
640+
{% endraw %}
614641
```
615642
616643
## Authoring Parameterized Jobs

0 commit comments

Comments
 (0)