You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: _docs/pipelines/triggers/git-triggers.md
+9-8Lines changed: 9 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -360,10 +360,11 @@ The Modified files option accepts glob expressions. The paths are relative to th
360
360
```
361
361
/package.json
362
362
/Dockerfile*
363
-
my-subproject/
363
+
my-subproject/*
364
+
my-subproject/**
364
365
my-subproject/sub-subproject/package.json
365
366
my-subproject//pom.xml
366
-
!config/
367
+
!config/**
367
368
368
369
```
369
370
@@ -375,9 +376,9 @@ You can also use relative paths with dot-slash. Therefore `./package.json` and `
375
376
You can also define[multiple expressions](http://tldp.org/LDP/GNU-Linux-Tools-Summary/html/x11655.htm){:target="\_blank"} like this, with a maximum of 65k characters for the field:
376
377
377
378
```
378
-
{app/,test/}
379
-
{/package.json,my-subproject/}
380
-
!{deployment/,/version.cfg}
379
+
{app/*,test/**}
380
+
{/package.json,my-subproject/**}
381
+
!{deployment/*,/version.cfg}
381
382
```
382
383
383
384
Once a commit happens to a code repository, Codefresh will see which files are changed from the Git provider and trigger the build only if the changed files match the glob expression. If there is no match no build will be triggered.
@@ -409,9 +410,9 @@ max-width="70%"
409
410
410
411
And then in the Git trigger for each one we set the modified files field to the following values:
411
412
412
-
* For the*build-nestjs-only* pipeline*MODIFIED FILES* has`my-nestjs-project/`.
413
-
* For the*build-java-only* pipeline*MODIFIED FILES* has`my-java-project/`.
414
-
* For the*build-rails-only* pipeline*MODIFIED FILES* has`my-rails-project/`.
413
+
* For the*build-nestjs-only* pipeline*MODIFIED FILES* has`my-nestjs-project/**`.
414
+
* For the*build-java-only* pipeline*MODIFIED FILES* has`my-java-project/**`.
415
+
* For the*build-rails-only* pipeline*MODIFIED FILES* has`my-rails-project/**`.
415
416
416
417
This way as multiple developers work on the Git repository only the affected projects will actually build. A change to the NestJS project will*not* build the Rails project as well. Also, if somebody changes*only* the README file and nothing else, no build will be triggered at all (which is a good thing as the source code is exactly the same).