C# Class ZocBuild.Database.ScriptRepositories.GitScriptRepository

Represents a script repository that stores build scripts in a Git repository.
The build script files in the distributed version repository must be organized with the same structure as required by FileSystemScriptRepository. The root location must contain subdirectories for each database schema, each named with the name of the schema. Within those directories should be a directory for each database object type: Function, Procedure, Type, View. Within those directories should be the build scripts, with file names ending with ".sql". The name of each file should be the same name as the database object it creates.
Inheritance: DvcsScriptRepositoryBase
显示文件 Open project: Zocdoc/ZocBuild.Database Class Usage Examples

Private Properties

Property Type Description
GetRepositoryPath Task

Public Methods

Method Description
GitScriptRepository ( DirectoryInfoBase scriptDirectory, string serverName, string databaseName, IExternalProcess gitExecutable, IFileSystem fileSystem, IParser sqlParser, ILogger logger, bool ignoreUnsupportedSubdirectories ) : System

Instantiates a Git script repository for the given database at the specified directory location.

GitScriptRepository ( string scriptDirectoryPath, string serverName, string databaseName, IExternalProcess gitExecutable, IFileSystem fileSystem, IParser sqlParser, ILogger logger, bool ignoreUnsupportedSubdirectories ) : System

Instantiates a Git script repository for the given database at the specified directory location.

Protected Methods

Method Description
GetDiffedFilesAsync ( ) : Task>

Gets the files that have changed between the revision specified by SourceChangeset and the current HEAD.

Private Methods

Method Description
GetRepositoryPath ( ) : Task

Gets the absolute path of the root of the Git repository.

Method Details

GetDiffedFilesAsync() protected method

Gets the files that have changed between the revision specified by SourceChangeset and the current HEAD.
protected GetDiffedFilesAsync ( ) : Task>
return Task>

GitScriptRepository() public method

Instantiates a Git script repository for the given database at the specified directory location.
public GitScriptRepository ( DirectoryInfoBase scriptDirectory, string serverName, string databaseName, IExternalProcess gitExecutable, IFileSystem fileSystem, IParser sqlParser, ILogger logger, bool ignoreUnsupportedSubdirectories ) : System
scriptDirectory DirectoryInfoBase The directory where build scripts are located.
serverName string The name of the database server.
databaseName string The name of the database.
gitExecutable IExternalProcess The Git executable for interfacing with the dvcs repository.
fileSystem IFileSystem An object that provides access to the file system.
sqlParser IParser The sql script parser for reading the SQL file contents.
logger ILogger A Logger
ignoreUnsupportedSubdirectories bool A flag indicating whether to ignore subdirectories that don't conform to the expected naming convention.
return System

GitScriptRepository() public method

Instantiates a Git script repository for the given database at the specified directory location.
public GitScriptRepository ( string scriptDirectoryPath, string serverName, string databaseName, IExternalProcess gitExecutable, IFileSystem fileSystem, IParser sqlParser, ILogger logger, bool ignoreUnsupportedSubdirectories ) : System
scriptDirectoryPath string The path to the directory where build scripts are located.
serverName string The name of the database server.
databaseName string The name of the database.
gitExecutable IExternalProcess The Git executable for interfacing with the dvcs repository.
fileSystem IFileSystem An object that provides access to the file system.
sqlParser IParser The sql script parser for reading the SQL file contents.
logger ILogger A Logger
ignoreUnsupportedSubdirectories bool A flag indicating whether to ignore subdirectories that don't conform to the expected naming convention.
return System