index.js
function( url ) {
	var trunkMatch = url.match( /(.*)\/(trunk|branches|tags)\/*(.*)\/*(.*)$/i );
	if ( trunkMatch ) {
		var rootUrl = trunkMatch[1];
		var projectName = rootUrl.match( /\/([^\/]+)$/ )[1];
		return {
			rootUrl: rootUrl,
			projectName: projectName,
			type: trunkMatch[2],
			typeName: trunkMatch[3],
			trunkUrl: trunkMatch[1] + "/trunk",
			tagsUrl: trunkMatch[1] + "/tags",
			branchesUrl: trunkMatch[1] + "/branches"
		};
	}
	throw new Error( "parseUrl: Url does not look like an SVN repository" );
}
function( url ) {
	var trunkMatch = url.match( /(.*)\/(trunk|branches|tags)\/*(.*)\/*(.*)$/i );
	if ( trunkMatch ) {
		var rootUrl = trunkMatch[1];
		var projectName = rootUrl.match( /\/([^\/]+)$/ )[1];
		return {
			rootUrl: rootUrl,
			projectName: projectName,
			type: trunkMatch[2],
			typeName: trunkMatch[3],
			trunkUrl: trunkMatch[1] + "/trunk",
			tagsUrl: trunkMatch[1] + "/tags",
			branchesUrl: trunkMatch[1] + "/branches"
		};
	}
	throw new Error( "parseUrl: Url does not look like an SVN repository" );
}
function ( url ) { var trunkMatch = url . match ( / (.*)\/(trunk|branches|tags)\/*(.*)\/*(.*)$ / i ) ; if ( trunkMatch ) { var rootUrl = trunkMatch [ 1 ] ; var projectName = rootUrl . match ( / \/([^\/]+)$ / ) [ 1 ] ; return { rootUrl : rootUrl , projectName : projectName , type : trunkMatch [ 2 ] , typeName : trunkMatch [ 3 ] , trunkUrl : trunkMatch [ 1 ] + "/trunk" , tagsUrl : trunkMatch [ 1 ] + "/tags" , branchesUrl : trunkMatch [ 1 ] + "/branches" } ; } throw new Error ( "parseUrl: Url does not look like an SVN repository" ) ; }
Parse a url for an SVN project repository and breaks it apart
@function parseUrl
@memberof util
@param {string} url - URL to parse
@returns {object}
Parse a url for an SVN project repository and breaks it apart