public static void InitialisePackageSources() { if (!File.Exists(Platform.PackageSourcesFile)) { var sources = new PackageSources(); sources.Sources.Add(new PackageSource { Name = "VitalElement", Url = "https://github.com/VitalElement/AvalonStudio.Repository" }); SerializedObject.Serialize(Platform.PackageSourcesFile, sources); } var result = SerializedObject.Deserialize <PackageSources>(Platform.PackageSourcesFile); Instance = result; }
public static void InitialisePackageSources() { if (!File.Exists(Platform.PackageSourcesFile)) { var sources = new PackageSources(); sources.Sources.Add(new PackageSource { Name = "VitalElement", Url = "https://github.com/VitalElement/AvalonStudio.Repository" }); SerializedObject.Serialize(Platform.PackageSourcesFile, sources); } var result = SerializedObject.Deserialize<PackageSources>(Platform.PackageSourcesFile); Instance = result; }