Due to some maintenance issues, this service has been switched in read-only mode, you can find more information about the why

and how to migrate your plugin documentation in this blogpost

Skip to end of metadata
Go to start of metadata

Plugin Information

No information for the plugin 'svnpublisher' is available. It may have been removed from distribution.

This plugin allows you to upload artifacts to a subversion repository. This is done via a delete/import of the items requested.

 This plugin is in its infancy and should be used with caution.


SVN URL

The SVN URL is the location you wish to upload the items to.

Target Path

The target path is the location of the target directory in hudson, if the project is not a maven project this can be the root location for the items to be imported.

Import Items

Each import item consists of 3 parts:

  • Pattern: A java regular expression pattern used to match the item as is exists in the target directory.
  • Name: If name is not left blank the item will be renamed upon import.
  • Path: If the item is to be imported into a directory other then the one given by the SVN URL this field can be used, this should always end with a forwardslash and it is always based off the location given in the SVN URL.

POM Path

The pom path is, if using a maven project, the location of the project's pom.xml. This is required if the following variable are to be used.

_MAJOR_ / _MINOR_ / _PATCH_ Paths

The _MAJOR_, _MINOR_, and _PATCH_ variables all require paths to their values from within the pom.xml's project node.

These paths are given in dot notation with index values available.

<project>
<versionA>1</versionA>
<properties>
<minor>2</minor>
<deep>
<patchBuild>3.456</patchBuild>

</deep>

</properties>

</project>

Using the above example the following paths and their results could be used:

versionA  -> 1

properties.minor  -> 2

properties.deep.patchBuild[0]  -> 3

properties.deep.patchBuild[1] -> 456

(warning) Currently only dot separated version numbers can be indexed.

Change Log

Version 0.1 (Jan 10, 2010)
  • Initial release

20 Comments

  1. Unknown User (jheckel@uillinois.edu)

    Has anyone used this plugin? I am new to Hudson but am wanting to have my artifacts from a Hudson build to be checked into Subversion afterwards. I am unclear if I should try using this plug in or use an ant task to check in to Subversion. Any thoughts or suggestions? I also don't see where this can be downloaded from.

  2. Unknown User (turboneat@gmail.com)

    You're going to think this is incredibly stupid. Where can I actually download this plugin?

    1. Unknown User (mindless)

      Not stupid at all.. looks like no release of this plugin was ever done.
      I'll release the "0.1" version now, so you can at least try out the work that was completed. Look for it soon in Manage Hudson / Manage Plugins / Available.

  3. Unknown User (coder)

    Sorry if this question has an obvious answer.  How do I go about using the WORKSPACE or other Hudson environment variables in the "Target path" field?  I've tried $WORKSPACE and ${WORKSPACE} and can't get favorable results.

    1. Unknown User (axel.heider@gi-de.com)

      Yes, this would help much.

      1. Unknown User (tomekwszelaki@gmail.com)

        Exactly, I've even tried to put full path "by hand" and it still returned the same error:"SVN Publisher: Error: target Directory not accessable:"

        1. Unknown User (chsia)

          I got the same error -
          SVN Publisher: Error: target Directory not accessable

          For example, let my test svn repository be

          http://mysource/svn/test/trunk

          under trunk I have two main directory:
          +src
          +bin

          all my source file are in src directory, the source files build by hudson, and the result executable file (named mybin) will be in bin directory.

          I've tried several setup like follows,

          SVN URL: http://mysource/svn/test/trunk
          Target Path: _WORKSPACE_/bin
          Pattern: mybin

          all the configuration I've tried result the "target Directory not accessable" messages.
          What is the right configuration for this case ?
          Thanks

          1. I also got the very same error message:

            "SVN Publisher: Error: target Directory not accessable"

            This is happening using either the _WORKSPACE_ variable or hard coding the path.

            Did someone find a way to set the target directory?

            Thanks

  4. Unknown User (bokc)

    This project is alive? I m very interesting by this plugin.

  5. Unknown User (dmoebius)

    @Augie: You can use _WORKSPACE_ instead of $WORKSPACE or ${WORKSPACE}.

    Another problem:

    When I use ".*\.zip" as Item Pattern and I have the following matching zip files in my workspace:
      fileA.zip, fileB.zip, fileC.zip, ...
    on svn import/commit they will be renamed to:
      fileA.zip, 1fileB.zip, 2fileC.zip, ...

    Looking from the source code (http://fisheye.jenkins-ci.org/browse/Hudson/trunk/hudson/plugins/svnpublisher/src/main/java/com/mtvi/plateng/subversion/SVNForceImport.java?r=HEAD) method forceImport(), there's no way to circumvent that other than not to use patterns that match more than one file.

  6. Unknown User (aeryn)

    It would be great if there was the ability to provide a check-in comment.  That way you can use the comment in conjunction with "Excluded Commit Messages" of subversion plugin to avoid triggering a build by hudson doing a check-in via this plug-in.  Bonus, if it can have some variables like build number, etc.

  7. Unknown User (santhosh.b@cleartrip.com)

    Is this plugin used by any one. I am giving the username and password for the "Hudson Management" console, but the authentication for the repo is still failing with the below error.  Any input on the same?

    13 Sep, 2010 7:51:26 PM com.mtvi.plateng.subversion.SVNForceImport forceImport
    SEVERE: *SVNForceImport Error: svn: Authentication required for '<http://aa.aa.aa.aa:80> CollabNet Subversion Repository'

    1. Unknown User (yzach)

      Just spent 2 hours trying to solve this issue... Here is the solution:

      Subversion credentials for SVN Publisher should be specified in Manage Hudson -> Configure System page.

  8. Unknown User (bjgr)

    No matter how I configure my project I keep having an authentication problem - "Authentication required for https://reponame". I have fillede the username and password in the Hudson main configuration, but this does not help me. Do you guys have any ideas? Is it a problem that the repo is httpS rather than http? The certificate is self signed, could that be a problem?

    1. Unknown User (ssi1111)

      Were you able to use this plugin?  I have similar auth failures even after setting up the username/password via Manage Hudson.

  9. Unknown User (aschilling)

    Everyone who has problems to get this running, here are some fixes we did in order to make it work after all "normal" tries didn't work out.

    To us it seems that the global authentication options taken from "Manage Jenkins" are not used for some reason (maybe broken after Jenkins fork?). However, you simply can put the two tags (<user></user> and <password></password>) into the configuration of each job. Then it works.
    Of course, whenever you change something in the config now those credentials will be overwritten again.

    However, you easily can fix that as well if you are able to administrate Jenkins the leet haxx0r way:

    1. Go to $JENKINS_HOME/plugins/svnpublisher/WEB-INF/classes/vom/mtvi/plateng/subversion/SVNPublisher
    2. open the file global.jelly and copy the two <f:entry> sections
    3. open the file config.jelly and insert the two sections at a desired position (e.g. at the very beginning) within the <j:jelly> section
    4. change the
      value=${descriptor.user}
      value=${descriptor.password}
      to
      value=${instance.user}
      value=${instance.password}
    5. remove the file global.jelly (or at least move it to some backup, just out of the jenkins directory)
    6. restart the jenkins service
      Now you can give the credentials per job and everything will work.
    7. happiness \o/

    Additional notes:

    1) the password is stored in plain text in the config file of the job... *sigh*
    2) when using regexp patterns to define the files to commit, for multiple files prefixes (numbers) are generated for whatever reason during checkin. We have no clue whether this is some leftover from debugging or whatever, however it's totally undesired. Thus we defined one item per file to checkin. This is also not optimal, but at least it works.

    Hope this is of help to all those that also didn't manage to get this working!

    1. Unknown User (bozu)

      I fixed the 0.1 to accept $WORKSPACE and also added the SVN auth workaround Andreas describes.

      Furthermore I changed the check-in behaviour:

      It is now commiting ony one update for several files fitting a pattern. its no more delete and insert per file.
      Only files with actual binary changes are checked in.

      If this is was you need, apply the following patchfile to the 0.1 SVN:

      svnPub0.2.svnpatch

  10. Unknown User (mako)

    on Windows _WORKSPACE_ is  /C:/jenkins/workspace/

    Of course, windows can't resolve this path
    SVN Publisher: Error: target Directory not accessable: /C:/jenkins/workspace/

    However it works for MacOS

    Finally, this plugin doesn't commit anything to SVN, I have the same settings as on screenshotArchiving artifacts
    workspace: /Library/Jenkins/jobs/xxx-yyy-zzz/workspace/
    Attempting to import to SVN: https://xxx/yyy/trunk
    SVN Publisher: target: /Library/Jenkins/jobs/xxx-yyy-zzz/workspace/zzzzzzzzzzz/bin/
    Finished: SUCCESS

  11. Unknown User (aytuncbeken)

    This plugin need some documentation about usage! It seems nice job but impossible to configure or debug the error. Especially "Directory not accessable" error comes with no explanation. 

  12. Unknown User (outerstone)

    Why the plugin don't is supported now?