Ejemplo n.º 1
0
        public static Deployment Create(string name, string listenStr, string attributes, string workingDir)
        {
            string path = workingDir + "\\phpDeploy.xml";

            Xml.XmlKeyValueFile xkvf = Xml.XmlKeyValueFile.Create(path);
            xkvf["name"]       = name;
            xkvf["listen_str"] = listenStr;
            xkvf["attributes"] = attributes;
            xkvf.Save();

            return(new Deployment(path));
        }
Ejemplo n.º 2
0
        public Deployment(string deploymentFilePath)
        {
            this._file = new Xml.XmlKeyValueFile(deploymentFilePath);

            if (!this.Valid)
            {
                return;
            }

            this.Name             = this._file["name"];
            this.WorkingDirectory = new FileInfo(deploymentFilePath).Directory.FullName;
            this.ListenString     = this._file["listen_str"];
            this.Attributes       = this._file["attributes"];
        }