SvnCommit.md

January 14, 2017 ยท View on GitHub

SvnCommit task

Commits a list of files (and directories). All files and directories must be part of the same SVN workspace.

Configuration

PropertyDescriptionDefault value
sourceA list of files and directories that should be committed. If these are not under version control already, they will be added first. If this list is empty of the files contain no modifications, no commit will be executed
recursiveAlso commit items in subdirectoriesfalse
commitMessageA commit message (optional)
usernameThe SVN username - leave empty if no authentication is required$project.svntools.username
passwordThe SVN password - leave empty if no authentication is required$project.svntools.password

Example

This Gradle script commits a changelog file to SVN:

apply plugin: "at.bxm.svntools"

version = "1.0-SNAPSHOT"

task createChangelog() {
  project.ext.changelog = file("changelog_${project.version}.txt")
  project.ext.changelog.text = "list of changes for this release..."
}

task commitChangelog(type: at.bxm.gradleplugins.svntools.tasks.SvnCommit, dependsOn: createChangelog) {
  source << project.ext.changelog
  commitMessage = "Changelog added"
}