Class SvnUtils


  • public final class SvnUtils
    extends Object
    The Class SvnUtils.
    • Method Detail

      • init

        public static void init()
        Initialise les diff�rentes factory pour le svn.
      • doCommit

        public static void doCommit​(String strPathFile,
                                    String strCommitMessage,
                                    ReleaseSvnCommitClient commitClient)
                             throws org.tmatesoft.svn.core.SVNException
        Commit.
        Parameters:
        strPathFile - the str path file
        strCommitMessage - the str commit message
        commitClient - the commit client
        Throws:
        org.tmatesoft.svn.core.SVNException - the SVN exception
      • doTagSite

        public static String doTagSite​(String strSiteName,
                                       String strTagName,
                                       String strSrcURL,
                                       String strDstURL,
                                       org.tmatesoft.svn.core.wc.SVNCopyClient copyClient)
                                throws org.tmatesoft.svn.core.SVNException
        Tag un site.
        Parameters:
        strSiteName - le nom du site
        strTagName - le nom du tag
        strSrcURL - the str src URL
        strDstURL - the str dst URL
        copyClient - le client svn permettant la copie
        Returns:
        string
        Throws:
        org.tmatesoft.svn.core.SVNException - the SVN exception
      • doSvnCheckout

        public static Long doSvnCheckout​(String strUrl,
                                         String strCheckoutBaseSitePath,
                                         ReleaseSvnCheckoutClient updateClient,
                                         CommandResult result)
                                  throws org.tmatesoft.svn.core.SVNException
        Do svn checkout.
        Parameters:
        strUrl - the str url
        strCheckoutBaseSitePath - the str checkout base site path
        updateClient - the update client
        result - the result
        Returns:
        the long
        Throws:
        org.tmatesoft.svn.core.SVNException - the SVN exception
      • getSvnSites

        public static fr.paris.lutece.util.ReferenceList getSvnSites​(String strUrlSite,
                                                                     org.tmatesoft.svn.core.wc.SVNClientManager clientManager)
                                                              throws org.tmatesoft.svn.core.SVNException
        Gets the svn sites.
        Parameters:
        strUrlSite - the str url site
        clientManager - the client manager
        Returns:
        the svn sites
        Throws:
        org.tmatesoft.svn.core.SVNException - the SVN exception
      • getLastRevision

        public static Long getLastRevision​(String strRepoPath,
                                           String strUserName,
                                           String strPassword)
        Gets the last revision.
        Parameters:
        strRepoPath - the str repo path
        strUserName - the str user name
        strPassword - the str password
        Returns:
        the last revision
      • update

        public static void update​(String strRepoPath,
                                  String strUserName,
                                  String strPassword)
        Update.
        Parameters:
        strRepoPath - the str repo path
        strUserName - the str user name
        strPassword - the str password
      • revert

        public static void revert​(String strRepoPath,
                                  String strCmUrl,
                                  String strUserName,
                                  String strPassword,
                                  Long revCurrentCommit,
                                  Long lRevertCommit)
        Revert.
        Parameters:
        strRepoPath - the str repo path
        strCmUrl - the str cm url
        strUserName - the str user name
        strPassword - the str password
        revCurrentCommit - the rev current commit
        lRevertCommit - the l revert commit
      • getSvnUrlTagSite

        public static String getSvnUrlTagSite​(String strScmUrl,
                                              String strTagName)
        Gets the svn url tag site.
        Parameters:
        strScmUrl - the str scm url
        strTagName - the str tag name
        Returns:
        the svn url tag site
      • getRepoUrl

        public static String getRepoUrl​(String strRepoUrl)
        Gets the repo url.
        Parameters:
        strRepoUrl - the str repo url
        Returns:
        the repo url
      • checkAuthentication

        public static boolean checkAuthentication​(String strUrl,
                                                  String strUserName,
                                                  String strPassword)
        Check authentication.
        Parameters:
        strUrl - the str url
        strUserName - the str user name
        strPassword - the str password
        Returns:
        true, if successful