Beispiel #1
0
 private static string GetSetting(Task<string> setting, string scSetting)
 {
     if (setting != null && setting.Value != null) {
         return String.Format(@" {0}= ""{1}""", scSetting, setting.Value);
     } else {
         return "";
     }
 }
Beispiel #2
0
 public Iis6WebSite()
 {
     Bindings = new[] {new Iis6WebSiteBinding {Port = 80}};
     ScriptMapsToAdd = new Iis6ScriptMap[0];
     Authentication = new[] {Iis6Authentication.Basic, Iis6Authentication.NTLM};
     AppPool = null;
     Started = true;
     AccessFlags = Iis6WebSiteAccessFlags.Read;
 }
Beispiel #3
0
 private string GetIncludeExcludeArgument(string argumentName, Task<IEnumerable<string>> categories)
 {
     if (categories.Value.Count() > 0)
     {
         return "/" + argumentName + "=" + String.Join(",", categories.Value.ToArray());
     } else
     {
         return "";
     }
 }
Beispiel #4
0
 public RemoteMachine(Task<string> remoteDeployDirectory, Task<string> localDeployDirectory, Parameter<string> stage, Parameter<string> machineParameter, string machineName)
 {
     LocalDeployDirectory = localDeployDirectory;
     Stage = stage;
     MachineParameter = machineParameter;
     MachineName = machineName;
     ArchiveCopiedToRemote = new Copy {
         FromPath = ".",
         ToPath = remoteDeployDirectory,
     };
 }
Beispiel #5
0
 public VisualStudioSolution()
 {
     MsBuildExe = Environment.ExpandEnvironmentVariables(@"%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe");
 }
Beispiel #6
0
 public Iis6Task()
 {
     Machine = "localhost";
 }
Beispiel #7
0
 private IEnumerable<string> GetValueOf(Task<IEnumerable<string>> paths)
 {
     return paths != null ? paths.Value : null;
 }
Beispiel #8
0
 public Copy(IFileSystemCopier fileSystemCopier)
 {
     FileSystemCopier = fileSystemCopier;
     DeleteToDirectory = true;
 }
Beispiel #9
0
        private ITask GetInvokeRemoteDeploy(Task<string> package)
        {
            Task<string> packageAfterDeploy = GetPreparedDeployPackage(package);

            if (Deploy != null) {
                return InvokeRemoteDeploy(packageAfterDeploy);
            } else {
                return packageAfterDeploy;
            }
        }
Beispiel #10
0
 private static Func<string, string> RewriteVersion(Task<string> version)
 {
     Regex asmVersion = new Regex(@"^(\s*\[assembly:\s*Assembly(File)?Version\s*\(\s*"").*?(""\s*\)\s*\])", RegexOptions.Multiline);
     return contents => {
         return asmVersion.Replace(contents, match => {
             return match.Groups[1].Value + version.Value + match.Groups[3].Value;
         });
     };
 }
Beispiel #11
0
 public Task<string> this[Task<string> filename]
 {
     get {
         return new All(Root, filename).WhenBuilt(() => Path.Combine(Root.Value, filename.Value));
     }
 }
Beispiel #12
0
 public WindowsService()
 {
     StartupType = WindowsServiceStartupType.Manual;
 }
Beispiel #13
0
 private Task<string> GetPreparedDeployPackage(Task<string> package)
 {
     return package.WithDependencyOn(PrepareDeploy(package));
 }
Beispiel #14
0
 public VisualStudioProject(VisualStudioSolution solution, Task<string> name)
 {
     Solution = solution;
     Name = name;
 }
Beispiel #15
0
 public DirectoryFiles(Task<string> root)
 {
     Root = root;
 }
Beispiel #16
0
 public Iis6AppPool()
 {
     Identity = new Iis6AppPoolIdentity {IdentityType = Iis6AppPoolIdentityType.NetworkService};
 }
Beispiel #17
0
 public NUnitTests()
 {
     NUnitConsolePath = @"c:\Program Files (x86)\NUnit\nunit-console.exe";
     ExcludeCategories = new string[0];
     IncludeCategories = new string[0];
 }
Beispiel #18
0
 public ITask CreateRemoteBounce(Task<string> bounceArguments, Task<string> workingDirectory, Task<string> machine)
 {
     return new SubBounce {
         BounceArguments = bounceArguments,
         WorkingDirectory = workingDirectory,
     };
 }
Beispiel #19
0
        private Task<string> CopyBounceDirectoryIntoPackage(Task<string> package)
        {
            Task<string> copiedBounceDirectory = new Copy
            {
                FromPath = Path.GetDirectoryName(BounceRunner.TargetsPath),
                ToPath = package.SubPath("Bounce"),
                Excludes = Copy.SvnDirectories,
            }.ToPath;

            var deletedBeforeBounce = new Delete {Path = copiedBounceDirectory.SubPath("beforebounce.*")};

            return copiedBounceDirectory.SubPath("..").WithDependencyOn(deletedBeforeBounce);
        }