-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
I have seen the example for creating a custom Git task, which is something along the lines of:
task cloneSimpleGitByGitTask(type: GitTask) {
forceDirectory = false//Just directly use the git executable.
command = 'clone' //Git Command
args = ['https://github.com/rcw3bb/simple-git.git', 'C:\\tmp\\simple-git'] //The git command arguments
}
Now, I would like to create a task that executes multiple Git tasks. For example, let's say I wanna do a checkout of some branch named my-branch, do a merge with some other branch called my-other-branch, followed by a push.
I would like to do that in a single Gradle task. What I would like to do would be something along the lines of:
task myGitActions() {
doLast {
// checkout impl here
// merge impl here
// push impl here
}
}
Yet, the only option I see is creating a bunch of tasks of the type GitTask, and finally bundle those via an additional task that just depends on all of those tasks.
Am I missing something here? Is there a way of achieving what I'm outlining above with this plugin?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels