Update 2016:
Upgrade to the latest VisualSVN Server version that includes a PowerShell module that adds a number of PowerShell cmdlets for Subverion server and repository administrators. Read VisualSVN Server | Scripting and Automation page.
The cmdlets should be very helpful in regular administration tasks and automation. Here is the complete list of VisualSVN Server PowerShell cmdlets: KB88: VisualSVN Server PowerShell Cmdlet Reference.
As @IvanZhakov already suggested, you can create a new repository using New-SvnRepository
cmdlet.
Here is an example of creating a new repository MyRepository and grabbing its URL parameter:
$repo = New-SvnRepository -Name MyRepository
$repo.URL
Outdated answer:
I assume you mean VisualSVN Server, not VisualSVN extension for Visual Studio.
You can create a repository with svnadmin create
command or using VisualSVN Server's WMI (Windows Management Instrumentation) provider. Here is the PowerShell command that creates a new repository "Repo1":
Invoke-WmiMethod -namespace root\VisualSVN -class VisualSVN_Repository -Name Create -ArgumentList Repo1
You can get URL of repository "Repo1" with the following PowerShell command:
Get-WmiObject -namespace root\VisualSVN -class VisualSVN_Repository | Select-Object -expandproperty URL | Select-String -SimpleMatch "Repo1"
If you want to explore VisualSVN Server WMI provider, you can check it's MOF file which is located in the following folder "%VISUALSVN_SERVER%\WMI" on the computer where
VisualSVN Server installed. Using this file as a reference you can write a program to manage VisualSVN Server on a various programming languages.
You may also want to check the MSDN article "Using WMI".
new->repository
© URL to clipboard
in visual SVN window... – Ramesh