Program.cs 910 B

123456789101112131415161718192021222324252627282930
  1. using MediaBrowser.ClickOnce;
  2. using System;
  3. using System.IO;
  4. namespace MediaBrowser.Server.Uninstall
  5. {
  6. /// <summary>
  7. /// Class Program
  8. /// </summary>
  9. class Program
  10. {
  11. /// <summary>
  12. /// Defines the entry point of the application.
  13. /// </summary>
  14. /// <param name="args">The args.</param>
  15. static void Main(string[] args)
  16. {
  17. new ClickOnceHelper(Globals.PublisherName, Globals.ProductName, Globals.SuiteName).Uninstall();
  18. // Delete all files from publisher folder and folder itself on uninstall
  19. var publisherFolder = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), Globals.PublisherName);
  20. if (Directory.Exists(publisherFolder))
  21. {
  22. Directory.Delete(publisherFolder, true);
  23. }
  24. }
  25. }
  26. }