Git commands¶
git.clone¶
{
"your-own-description": {
"sequence": 1,
"command": "git.clone",
"params": {
"git_repo_path": "/full/path/to/repo",
"git_repo_url": "https://github.com/munstermedia/demo.git"
}
}
}
Functionality:
- Checks if repo path exists.. if not it will ask to reinstall and it will reset/remove all existing code in the path.
- Clones the repository to the path
git.deploy¶
{
"your-own-description": {
"sequence": 1,
"command": "git.deploy",
"params": {
"git_repo_url": "http://www.somegit.repo",
"git_repo_path": "/full/path/to/repo",
"git_source_path": "/full/path/to/source/%(tag)s",
"git_branch": "deploy-0.0.1"
}
}
}
Functionality:
It will use the code in the repo path to go to a certain branch/tag. This will be copied to a tag path so you’ll have versioned codebases living next to each other.
- Branch in params is required, you can use input_params to make this dynamic.
- If repo path is not existing it will exit. You’ll need a valid cloned repo path
- If target path is allready existing it will remove it and all it’s content. And deploy a completely new version.
- Allow updates submodules by running ‘git submodule update’