Permalink
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
16 lines (12 sloc) 558 Bytes
import clr
clr.AddReferenceToFile("NanoByte.Common.dll", "ZeroInstall.Services.dll", "ZeroInstall.Store.dll")
import sys
from NanoByte.Common.Tasks import CliTaskHandler
from ZeroInstall.Services import ServiceLocator
from ZeroInstall.Store import FeedUri
from ZeroInstall.Store.Model import Requirements
services = ServiceLocator(CliTaskHandler())
selections = services.Solver.Solve(Requirements(sys.argv[1]))
missing = services.SelectionsManager.GetUncachedImplementations(selections)
services.Fetcher.Fetch(missing)
services.Executor.Start(selections)