Example #1
0
        public PackageManifest Build()
        {
            var args = Args.Value;

            if (InstallMethod.Value == InstallMethodTypes.Squirrel || JsonEquality.Equal(args, new InstallArgs()))
            {
                args = null;
            }

            return(new PackageManifest
            {
                Id = Id.Value,
                Name = Name.Value,
                Version = Version.Value,

                Home = Home.Value,
                Repo = Repo.Value,
                License = License.Value,

                InstallMethod = InstallMethod.Value,
                Installers = Installers.Select(c => c.Build()).OrderBy(c => c.Architecture).ToList(),
                Args = args,
                Tag = Tag
            });
        }