public static void Execute(string serverName, string databaseName, string path = ".", bool useTransactions = false, bool requireRollback = false, string username = null, string password = null) { var scriptTarget = (!string.IsNullOrWhiteSpace(username) && !string.IsNullOrWhiteSpace(password)) ? new SqlDatabase(serverName, databaseName, username, password) : new SqlDatabase(serverName, databaseName); foreach (var releaseDirectoryPath in Directory.GetDirectories(path, "Release *")) { var scriptSource = new FolderContainingNumberedSqlScripts(releaseDirectoryPath, "*.sql"); var updater = new Updater<ITextScriptTarget>(scriptSource, scriptTarget, requireRollback, useTransactions); updater.ApplyScripts(); } }