public static void Main(string[] args) { Encoding.RegisterProvider(CodePagesEncodingProvider.Instance); if (ProgramSettings.Settings.CheckUpdate) { UpdateController.AddUpdate("RemoteFork", new GithubProvider("RemoteFork", "ShutovPS/RemoteFork/RemoteFork", true), AssemblyVersionChecker.GetInstalledVersionNumber()); Task.Run(CheckForUpdate, _cancellationToken); } server = new Server(ProgramSettings.Settings.IpAddress, ProgramSettings.Settings.Port); server.Start(); _cancellationTokenSource.Cancel(); }
public PluginInstance(string key, Assembly assembly, Type type, PluginAttribute attribute) { Key = key; Attribute = attribute; Assembly = assembly; _type = type; if (ProgramSettings.Settings.CheckUpdate) { if (!string.IsNullOrEmpty(attribute.Github) && attribute.Github.Count(c => c == '/') == 2) { UpdateController.AddUpdate(attribute.Id, new GithubProvider(attribute.Id, attribute.Github, false), attribute.Version); } } }