@@ -12,59 +12,6 @@ specifying conditions in your build configuration (your `.travis.yml` file).
12
12
See [ Conditional Builds, Stages, and Jobs] ( /user/conditional-builds-stages-jobs )
13
13
for details.
14
14
15
- ## Examples
16
-
17
- Build only when on the master branch (note for PRs this is the base branch
18
- name):
19
-
20
- ```
21
- branch = master
22
- ```
23
-
24
- Build only when the tag name matches the given regular expression:
25
-
26
- ```
27
- tag =~ /^(v1|v2)/
28
- ```
29
-
30
- Build only when the build type is either ` push ` or ` pull_request ` :
31
-
32
- ```
33
- type IN (push, pull_request)
34
- ```
35
-
36
- Build only when the branch name is not be one of several names:
37
-
38
- ```
39
- branch NOT IN (master, dev)
40
- ```
41
-
42
- Build only when the sender login name matches the given name - use quotes for
43
- strings that contain spaces or special characters (the sender is the GitHub user who creates a build):
44
-
45
- ```
46
- sender = my_account
47
- sender != "deploy bot"
48
- ```
49
-
50
- Do not build on forks:
51
-
52
- ```
53
- fork = false
54
- ```
55
-
56
- Build only when the commit message matches against the given regular expression:
57
-
58
- ```
59
- commit_message !~ /(no-deploy|wip)/
60
- ```
61
-
62
- Build only on Linux:
63
-
64
- ```
65
- os = linux
66
- ```
67
-
68
15
## Integration
69
16
70
17
Conditions are parsed and evaluated using [ this library] ( https://github.com/travis-ci/travis-conditions/pull/1 ) ,
@@ -366,3 +313,56 @@ if: |
366
313
branch = master AND \
367
314
type = push
368
315
```
316
+
317
+ ## Examples
318
+
319
+ Build only when on the master branch (note for PRs this is the base branch
320
+ name):
321
+
322
+ ```
323
+ branch = master
324
+ ```
325
+
326
+ Build only when the tag name matches the given regular expression:
327
+
328
+ ```
329
+ tag =~ /^(v1|v2)/
330
+ ```
331
+
332
+ Build only when the build type is either ` push ` or ` pull_request ` :
333
+
334
+ ```
335
+ type IN (push, pull_request)
336
+ ```
337
+
338
+ Build only when the branch name is not be one of several names:
339
+
340
+ ```
341
+ branch NOT IN (master, dev)
342
+ ```
343
+
344
+ Build only when the sender login name matches the given name - use quotes for
345
+ strings that contain spaces or special characters (the sender is the GitHub user who creates a build):
346
+
347
+ ```
348
+ sender = my_account
349
+ sender != "deploy bot"
350
+ ```
351
+
352
+ Do not build on forks:
353
+
354
+ ```
355
+ fork = false
356
+ ```
357
+
358
+ Build only when the commit message matches against the given regular expression:
359
+
360
+ ```
361
+ commit_message !~ /(no-deploy|wip)/
362
+ ```
363
+
364
+ Build only on Linux:
365
+
366
+ ```
367
+ os = linux
368
+ ```
0 commit comments