Use powershell to control the svn server, but unfortunately the svn server needs to be valid from VisualSVN Server 3.4

https://www.visualsvn.com/support/topic/00088/


This reference provides descriptions and examples for all VisualSVN Server PowerShell cmdlets. Cmdlets are listed in alphabetical order based on the verb at the beginning of the cmdlet.


Cmdlet Description

Add-SvnAccessRule Adds a new rule that controls access to Subversion repositories.
Add-SvnRepositoryHook Adds a new repository hook to Subversion repositories.
Backup-SvnRepository Performs a backup of the Subversion repository.
Convert-SvnRepository Converts a regular Subversion repository to a distributed VDFS format and vice versa.
Disable-SvnJob Disables a background job.
Enable-SvnJob Enables a previously disabled background job.
Get-SvnAccessRule Retrieves a list of rules that control access to Subversion repositories.
Get-SvnJob Retrieves a list of configured background jobs.
Get-SvnRepository Retrieves a list of Subversion repositories.
Get-SvnRepositoryHook Retrieves a list of the repository hooks configured in VisualSVN Server.
Get-SvnRepositoryItem Retrieves a list of files and folders for the specified path in a Subversion repository.
Get-SvnRepositoryReplication Gets the replication settings for a master VDFS repository.
Get-SvnServerConfiguration Returns the configuration settings of a VisualSVN Server instance.
Import-SvnRepository Imports a repository or a repository dump from the specified path.
Measure-SvnRepository Measures the disk space occupied by Subversion repositories.
New-SvnRepository Creates a Subversion repository.
New-SvnRepositoryItem Creates a folder in a Subversion repository.
Remove-SvnAccessRule Deletes one or more rules that control access to Subversion repositories.
Remove-SvnRepository Deletes a Subversion repository.
Remove-SvnRepositoryHook Deletes one or more repository hooks.
Remove-SvnRepositoryItem Deletes a file or a folder in a Subversion repository.
Rename-SvnRepository Renames a Subversion repository.
Restore-SvnRepository Restores a Subversion repository from backup.
Resume-SvnRepository Resumes a suspended (read-only) VDFS repository.
Select-SvnAccessRule Returns an effective list of access rules for the specified path in a Subversion repository.
Set-SvnAccessRule Modifies an existing access rule that controls access to Subversion repositories.
Set-SvnRepository Modifies settings for a Subversion repository.
Set-SvnRepositoryHook Modifies the content of existing repository hooks.
Set-SvnRepositoryReplication Modifies replication settings for a master VDFS repository.
Set-SvnServerConfiguration Modifies the VisualSVN Server configuration settings.
Start-SvnJob Starts a background job.
Stop-SvnJob Stops a background job.
Suspend-SvnRepository Makes a VDFS repository read-only temporarily.
Switch-SvnRepository Switches replication role for a VDFS repository.
Sync-SvnRepository Forces a slave VDFS repository to replicate data from the master repository.
Test-SvnRepository Verifies the integrity of data stored in a Subversion repository.

Add-SvnAccessRule

Available since VisualSVN Server 3.4.

Adds a new access rule to Subversion repositories. Access rules can be configured globally for all repositories or for a specific path in a particular repository.


Note


Note
Add-SvnAccessRule and other cmdlets that work with access rules are currently available only if VisualSVN Server is configured to use Windows Authentication. See KB39: Understanding VisualSVN Server Authentication options for further details.
Example 1: add a global read/write access rule for a Devs user group
PS C:\> Add-SvnAccessRule -Global -AccountName contoso\Devs -Access ReadWrite

Example 2: add a read-only access for the trunk folder in the MyRepo repository
PS C:\> Add-SvnAccessRule MyRepo -Path /trunk -AccountName contoso\Devs -Access ReadOnly

Example 3: add a global read-only access for the BUILTIN\Users account using its SID string
PS C:\> Add-SvnAccessRule -Global -AccountId S-1-5-32-545 -Access ReadOnly



Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326331175&siteId=291194637