예제 #1
0
 private static PackageVersionUpload BuildPackageVersionUpload(PackageUploadRequestBody pkgHeader, string zipPath )
 {
     return new PackageVersionUpload(  pkgHeader.name,
                                         pkgHeader.version,
                                         pkgHeader.description,
                                         pkgHeader.keywords,
                                         pkgHeader.contents,
                                         "dynamo",
                                         pkgHeader.engine_version,
                                         pkgHeader.engine_metadata,
                                         pkgHeader.group,
                                         zipPath,
                                         pkgHeader.dependencies);
 }
예제 #2
0
 public PackageUploadHandle(PackageUploadRequestBody header)
 {
     this.Header = header;
 }
예제 #3
0
        private static void WritePackageHeader(PackageUploadRequestBody pkgHeader, DirectoryInfo rootDir)
        {
            // build the package header json, which will be stored with the pkg
            var jsSer = new JsonSerializer();
            var pkgHeaderStr = jsSer.Serialize(pkgHeader);

            // write the pkg header to the root directory of the pkg
            var headerPath = Path.Combine(rootDir.FullName, "pkg.json");
            if (File.Exists(headerPath)) File.Delete(headerPath);
            File.WriteAllText(headerPath, pkgHeaderStr);
        }
예제 #4
0
 public Package(string directory, string name, string versionName, string license)
 {
     RootDirectory = directory;
     Name = name;
     License = license;
     VersionName = versionName;
     LoadedTypes = new ObservableCollection<Type>();
     LoadedAssemblies = new ObservableCollection<PackageAssembly>();
     Dependencies = new ObservableCollection<PackageDependency>();
     LoadedCustomNodes = new ObservableCollection<CustomNodeInfo>();
     AdditionalFiles = new ObservableCollection<PackageFileInfo>();
     Header = PackageUploadBuilder.NewRequestBody(this);
 }
예제 #5
0
        public PackageUpload(PackageUploadRequestBody requestBody, string zipFile )
        {
            this.ZipFile = zipFile;
            this.RequestBody = requestBody;

        }
예제 #6
0
 public PackageUpload(PackageUploadRequestBody requestBody, IEnumerable<string> files)
 {
     this.Files = files;
     this.RequestBody = requestBody;
 }
 public PackageUpload(PackageUploadRequestBody requestBody, string zipFile)
 {
     this.ZipFile     = zipFile;
     this.RequestBody = requestBody;
 }
 public PackageUpload(PackageUploadRequestBody requestBody, IEnumerable <string> files)
 {
     this.Files       = files;
     this.RequestBody = requestBody;
 }