public LauncherApp() { clock = Stopwatch.StartNew(); IsProcessing = false; // TODO: Add a way to clear the cache more othen than the default nuget (>= 200 files) // Check config file DebugStep("Load store"); // Get the package name and executable to launch/update var thisExeDirectory = Path.GetDirectoryName(typeof(LauncherApp).Assembly.Location); store = new NugetStore(thisExeDirectory); store.Manager.Logger = this; store.SourceRepository.Logger = this; mainPackage = store.MainPackageId; vsixPackage = store.VSIXPluginId; SdkVersionManager = new SDKVersionManager(store.Manager, mainPackage, vsixPackage); mainExecutable = store.Settings.GetConfigValue(MainExecutableKey); if (string.IsNullOrWhiteSpace(mainExecutable)) { throw new LauncherAppException("Invalid configuration. Expecting [{0}] in config", MainExecutableKey); } var aggregateRepo = (AggregateRepository)store.Manager.SourceRepository; foreach (var repo in aggregateRepo.Repositories) { var progressProvider = repo as IProgressProvider; if (progressProvider != null) { progressProvider.ProgressAvailable += OnProgressAvailable; } } downloadThreads = new List <Thread>(); // Update the targets everytime the launcher is used in order to make sure targets are up-to-date // with packages installed (rewrite for example after a self-update) store.UpdateTargets(); }
public LauncherApp() { clock = Stopwatch.StartNew(); IsProcessing = false; // TODO: Add a way to clear the cache more othen than the default nuget (>= 200 files) // Check config file DebugStep("Load store"); // Get the package name and executable to launch/update var thisExeDirectory = Path.GetDirectoryName(typeof(LauncherApp).Assembly.Location); store = new NugetStore(thisExeDirectory); store.Manager.Logger = this; store.SourceRepository.Logger = this; mainPackage = store.MainPackageId; vsixPackage = store.VSIXPluginId; SdkVersionManager = new SDKVersionManager(store.Manager, mainPackage, vsixPackage); mainExecutable = store.Settings.GetConfigValue(MainExecutableKey); if (string.IsNullOrWhiteSpace(mainExecutable)) { throw new LauncherAppException("Invalid configuration. Expecting [{0}] in config", MainExecutableKey); } var aggregateRepo = (AggregateRepository)store.Manager.SourceRepository; foreach (var repo in aggregateRepo.Repositories) { var progressProvider = repo as IProgressProvider; if (progressProvider != null) { progressProvider.ProgressAvailable += OnProgressAvailable; } } downloadThreads = new List<Thread>(); // Update the targets everytime the launcher is used in order to make sure targets are up-to-date // with packages installed (rewrite for example after a self-update) store.UpdateTargets(); }