示例#1
0
        public Prompt(IPromptConfiguration configuration)
        {
            try
            {
                // If Configuration is null, use default settings
                Configuration = configuration ?? new PromptConfiguration();

                ReadLine.HistoryEnabled = string.Equals(Configuration.GetOption("HistoryEnabled"), true.ToString());

                BuildCommands.ScanForPrompt(this);

                HistoryFile.Load(configuration);
            }
            catch (Exception e)
            {
                // Don't allow an exception to crash the application by a throw
                // Show the error so that an developer can fix the problem.
                Console.WriteLine(e);
            }
        }
示例#2
0
 public void Rescan()
 {
     BuildCommands.ScanForPrompt(prompt);
 }