How to use wildcards in Buddy
Wildcard patterns let you specify which branches will trigger the pipeline execution. This feature is especially useful for testing and deploying multiple branches on development servers.
How to run application tests on push to any branch in the repository
- Create a new pipeline
- Set the trigger mode to 'On push'
- Set the wildcard to
*
- Add build action for your type of language/framework (eg. PHP)
This way Buddy will automatically test your app on every push, no matter what branch you pushed to.
How to test and deploy all 'dev' branches
- Create a new pipeline
- Set the trigger mode to 'On Push'
- Set the wildcard to
dev/*
- Add build action for your type of language/framework (eg. Node.js)
- Add deployment action for your type of server (eg. SFTP)
This way Buddy will test and deploy your app parameterizing the path according to the deployed branch
Wildcard syntax
In Buddy you can use two kinds of syntax to define wildcard patterns:
SIMPLE
Patterns are created with an asterisk *
, for example:
*
- all branchesdev*
- all branches starting with dev
REGEX
The whole pattern must be enclosed in brackets, eg:
(.*)
- all branches(dev.*)
- all branches starting with dev(^((?!(master)$).)*$)
- all branches except master branch
Jarek Dylewski
Customer Support
A journalist and an SEO specialist trying to find himself in the unforgiving world of coders. Gamer, a non-fiction literature fan and obsessive carnivore. Jarek uses his talents to convert the programming lingo into a cohesive and approachable narration.