Exemplo n.º 1
0
 def add_arguments(self, parser: argparse.ArgumentParser) -> None:
     groups_group.add_to_parser(parser)
     save_strategy_group.add_to_parser(parser)
     update_strategy_group.add_to_parser(parser)
     install_group.add_to_parser(parser)
     parser.add_argument(
         "-u",
         "--unconstrained",
         action="store_true",
         default=False,
         help="Ignore the version constraint of packages",
     )
     parser.add_argument(
         "-t",
         "--top",
         action="store_true",
         help="Only update those list in pyproject.toml",
     )
     parser.add_argument(
         "--dry-run",
         "--outdated",
         action="store_true",
         dest="dry_run",
         help=
         "Show the difference only without modifying the lockfile content",
     )
     parser.add_argument("packages",
                         nargs="*",
                         help="If packages are given, only update them")
     parser.set_defaults(dev=None)
Exemplo n.º 2
0
 def add_arguments(self, parser: argparse.ArgumentParser) -> None:
     parser.add_argument(
         "-f",
         "--format",
         choices=FORMATS.keys(),
         default="requirements",
         help="Specify the export file format",
     )
     groups_group.add_to_parser(parser)
     parser.add_argument(
         "--without-hashes",
         dest="hashes",
         action="store_false",
         default=True,
         help="Don't include artifact hashes",
     )
     parser.add_argument(
         "-o",
         "--output",
         help="Write output to the given file, or print to stdout if not given",
     )
     parser.add_argument(
         "--pyproject",
         action="store_true",
         help="Read the list of packages from pyproject.toml",
     )
Exemplo n.º 3
0
 def add_arguments(self, parser: argparse.ArgumentParser) -> None:
     groups_group.add_to_parser(parser)
     install_group.add_to_parser(parser)
     parser.add_argument(
         "--no-lock",
         dest="lock",
         action="store_false",
         default=True,
         help="Don't do lock if lockfile is not found or outdated.",
     )
Exemplo n.º 4
0
Arquivo: sync.py Projeto: pawamoy/pdm
 def add_arguments(self, parser: argparse.ArgumentParser) -> None:
     groups_group.add_to_parser(parser)
     dry_run_option.add_to_parser(parser)
     parser.add_argument(
         "-r",
         "--reinstall",
         action="store_true",
         help="Force reinstall existing dependencies",
     )
     clean_group.add_to_parser(parser)
     install_group.add_to_parser(parser)
Exemplo n.º 5
0
 def add_arguments(self, parser: argparse.ArgumentParser) -> None:
     groups_group.add_to_parser(parser)
     install_group.add_to_parser(parser)
     dry_run_option.add_to_parser(parser)
     lockfile_option.add_to_parser(parser)
     parser.add_argument(
         "--no-lock",
         dest="lock",
         action="store_false",
         default=True,
         help="Don't do lock if the lock file is not found or outdated",
     )
     parser.add_argument(
         "--check",
         action="store_true",
         help="Check if the lock file is up to date and fail otherwise",
     )