Beispiel #1
0
        public static Command GetCommand()
        {
            var command = new Command("remove", LocalizableStrings.NetRemoveCommand);

            command.AddArgument(ProjectArgument);
            command.AddCommand(RemovePackageParser.GetCommand());
            command.AddCommand(RemoveProjectToProjectReferenceParser.GetCommand());

            return(command);
        }
Beispiel #2
0
 public static Command Remove() =>
 Create.Command("remove",
                LocalizableStrings.NetRemoveCommand,
                Accept.ExactlyOneArgument()
                .DefaultToCurrentDirectory()
                .With(name: CommonLocalizableStrings.ProjectArgumentName,
                      description: CommonLocalizableStrings.ProjectArgumentDescription)
                .DefaultToCurrentDirectory(),
                CommonOptions.HelpOption(),
                RemovePackageParser.RemovePackage(),
                RemoveProjectToProjectReferenceParser.RemoveReference());
Beispiel #3
0
        private static Command ConstructCommand()
        {
            var command = new DocumentedCommand("remove", DocsLink, LocalizableStrings.NetRemoveCommand);

            command.AddArgument(ProjectArgument);
            command.AddCommand(RemovePackageParser.GetCommand());
            command.AddCommand(RemoveProjectToProjectReferenceParser.GetCommand());

            command.Handler = CommandHandler.Create <ParseResult>((parseResult) => parseResult.HandleMissingCommand());

            return(command);
        }