ZeroInstall.Commands.Utils.Exporter.DeployBootstrap C# (CSharp) Метод

DeployBootstrap() приватный Метод

private DeployBootstrap ( [ handler, [ mode ) : void
handler [
mode [
Результат void
        private void DeployBootstrap([NotNull] ITaskHandler handler, [NotNull] string mode)
        {
            string appName = _selections.Name ?? "application";
            string fileName = (_architecture.OS == OS.Windows)
                ? mode + " " + appName + ".exe"
                : mode + "-" + appName.ToLowerInvariant().Replace(" ", "-") + ".sh";

            var source = new Uri("https://0install.de/bootstrap/" +
                                 "?platform=" + (_architecture.OS == OS.Windows ? "windows" : "linux") +
                                 "&mode=" + mode +
                                 "&name=" + HttpUtility.UrlEncode(appName) +
                                 "&uri=" + HttpUtility.UrlEncode(_selections.InterfaceUri.ToStringRfc()));
            string target = Path.Combine(_destination, fileName);

            handler.RunTask(new DownloadFile(source, target));
            if (UnixUtils.IsUnix)
                UnixUtils.SetExecutable(target, executable: true);
        }
    }