当前位置: 首页>>代码示例>>C#>>正文


C# PackageManager.AddFeed方法代码示例

本文整理汇总了C#中PackageManager.AddFeed方法的典型用法代码示例。如果您正苦于以下问题:C# PackageManager.AddFeed方法的具体用法?C# PackageManager.AddFeed怎么用?C# PackageManager.AddFeed使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PackageManager的用法示例。


在下文中一共展示了PackageManager.AddFeed方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: StartPackageManager

        internal void StartPackageManager()
        {
            // ok, we're looking like we're ready to need the package manager.
            // make sure its running.
            PackageManager.Instance.ConnectAndWait("autopackage", null, 15000);

            PackageManager = PackageManager.Instance;
            PackageManager.AddFeed(Environment.CurrentDirectory,true);

            if (AutopackageMain._verbose) {
                PackageManager.SetLogging(true, true, true);
            }
        }
开发者ID:riverar,项目名称:devtools,代码行数:13,代码来源:PackageSource.cs

示例2: Main

        /// <summary>
        ///   The (non-static) startup method
        /// </summary>
        /// <param name = "args">
        ///   The command line arguments.
        /// </param>
        /// <returns>
        ///   Process return code.
        /// </returns>
        protected override int Main(IEnumerable<string> args)
        {
            try
            {

                _package.CertificateFile = _certificateSettings["#CurrentCertificate"].EncryptedStringValue;

                PackageManager.Instance.Connect("autopackage");
                if (!PackageManager.Instance.IsReady.WaitOne(5000)) {
                    //Verbose("# not connected...");
                    throw new ConsoleException("# Unable to connect to CoApp Service.");
                }

                _pkgMgr = PackageManager.Instance;
                PropertySheet propSheet;

                _pkgMgr.AddFeed(Environment.CurrentDirectory);

                var exceptions = new List<Exception>();
                #region command line parsing
                var configLoaded = false;
                // default:
                var options = args.Switches();
                var parameters = args.Parameters();

                foreach (var arg in options.Keys)
                {
                    var argumentParameters = options[arg];

                    switch (arg)
                    {
                        /* options  */

                        /* global switches */
                        case "load-config":
                            // all ready done, but don't get too picky.
                            break;
                        case "load":
                            propSheet = PropertySheet.Load(argumentParameters.First());
                            PropSheetParser parser = new PropSheetParser(_package);
                            //parser.Parse(propSheet);
                            configLoaded = true;

                            break;
                        case "nologo":
                            this.Assembly().SetLogo(string.Empty);
                            break;

                        case "show-tools":
                            _showTools = Boolean.Parse(argumentParameters.First());
                            break;

                        case "password":
                            _package.CertificatePassword = argumentParameters.First();
                            break;

                        case "autosign":
                            _autosign = true;
                            break;

                        case "remember":
                            _remember = true;
                            break;

                        case "accept-old-bs":
                            _acceptOldBs = true;
                            break;
                        case "help":
                            return Help();

                        default:
                            throw new ConsoleException(Resources.UnknownParameter, arg);

                    }
                }

                Logo();

                if (!configLoaded)
                    throw new ConsoleException(Resources.NoConfigFileLoaded);
                #endregion

                // GS01: I'm putting this in here so that feed resoltion happens before we actually get around to doing something.
                // Look into the necessity later.
                // Tasklet.WaitforCurrentChildTasks();

                #region Tool Scanning

                Console.Write(Resources.ToolLookup);

                _candle = new ProcessUtility(ProgramFinder.ProgramFilesAndDotNet.ScanForFile("candle.exe"));
//.........这里部分代码省略.........
开发者ID:coapp-deprecated,项目名称:autopackage_old,代码行数:101,代码来源:AutopackageMain.cs


注:本文中的PackageManager.AddFeed方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。