public XWorld( FileSystem fileSystem, IRootedWorldName worldName, WorldStore worldStore, IEnvLocalFeedProvider localFeeds, SecretKeyStore keyStore, ArtifactCenter artifacts, CommandRegister commandRegister, IBasicApplicationLifetime appLife, Initializer initializer) : base(initializer) { _localFeeds = localFeeds; _fileSystem = fileSystem; _userMonitorFilter = initializer.Monitor.Output.Clients.OfType <IActivityMonitorFilteredClient>().FirstOrDefault(); if (_userMonitorFilter == null) { throw new InvalidOperationException(); } bool isPublic = initializer.Reader.HandleRequiredAttribute <bool>("IsPublic"); _world = new World(commandRegister, artifacts, worldStore, worldName, isPublic, _localFeeds, keyStore, _userMonitorFilter, appLife) { VersionSelector = new ReleaseVersionSelector() }; _world.DumpWorldStatus += (o, e) => OnDumpWorldStatus(e.Monitor); initializer.Services.Add(_world); fileSystem.ServiceContainer.Add <ISolutionDriverWorld>(_world); }
public XArtifacts( Initializer initializer, ArtifactCenter artifactCenter) : base(initializer) { initializer.Services.Add(this); var feeds = initializer.Reader.WithRequiredChild("SourceFeeds").WithChildren(true); var repositories = initializer.Reader.WithRequiredChild("TargetRepositories").WithChildren(true); artifactCenter.Initialize(initializer.Monitor, feeds, repositories); }
public XArtifactCenter( Initializer initializer, FileSystem fs) : base(initializer) { ArtifactCenter = new ArtifactCenter(); fs.ServiceContainer.Add(ArtifactCenter); initializer.Services.Add(ArtifactCenter); // Quick & dirty registration. ArtifactType.Register("NuGet", true, ';'); ArtifactType.Register("NPM", true); ArtifactType.Register("CKSetup", false); }
public XNuGetClient( HttpClient sharedHttpClient, SecretKeyStore secretKeyStore, ArtifactCenter artifact, IEnvLocalFeedProvider localFeedProvider, FileSystem fs, Initializer initializer) : base(initializer) { _nuGetClient = new NuGetClient(sharedHttpClient, secretKeyStore); localFeedProvider.Register(new EnvLocalFeedProviderNuGetHandler()); fs.ServiceContainer.Add(_nuGetClient); artifact.Register(_nuGetClient); initializer.Services.Add(this); }