jelle-s/aoc

AOC 框架基本命令

1.1.0 2023-12-03 13:10 UTC

This package is auto-updated.

Last update: 2024-09-03 14:37:37 UTC


README

该存储库包含用于使 aoc 解决方案项目的基本命令,可以通过单个命令启动和运行。

安装

composer require jelle-s/aoc

配置

以下环境变量可以/应该配置

  • AOC_COOKIE:您的 advent of code 会话 Cookie。

命令

初始化

vendor/bin/aoc init 1 1 2022
Description:
  Initialise all scaffolding for an aoc puzzle solution.

Usage:
  init [<part> [<day> [<year>]]]

Arguments:
  part                  The part of the puzzle, defaults to part 1 [default: 1]
  day                   The day of the puzzle, defaults to the current day
  year                  The year of the puzzle, defaults to the current year

Options:
  -h, --help            Display help for the given command. When no command is given display help for the run command
  -q, --quiet           Do not output any message
  -V, --version         Display this application version
      --ansi|--no-ansi  Force (or disable --no-ansi) ANSI output
  -n, --no-interaction  Do not ask any interactive question
  -v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug

初始化项目

vendor/bin/aoc init-project ~/projects/aoc2022 2022
Description:
  Initialise all scaffolding for an aoc solution project.

Usage:
  init-project <dir> [<year>]

Arguments:
  dir                   The directory to create the project in
  year                  The year of the puzzle, defaults to the current year

Options:
  -h, --help            Display help for the given command. When no command is given display help for the run command
  -q, --quiet           Do not output any message
  -V, --version         Display this application version
      --ansi|--no-ansi  Force (or disable --no-ansi) ANSI output
  -n, --no-interaction  Do not ask any interactive question
  -v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug

运行 [默认命令]

vendor/bin/aoc run 1 1 2022
Description:
  Run a puzzle solution.

Usage:
  run [<part> [<day> [<year>]]]

Arguments:
  part                  The part of the puzzle, defaults to part 1 [default: 1]
  day                   The day of the puzzle, defaults to the current day
  year                  The year of the puzzle, defaults to the current year

Options:
  -h, --help            Display help for the given command. When no command is given display help for the run command
  -q, --quiet           Do not output any message
  -V, --version         Display this application version
      --ansi|--no-ansi  Force (or disable --no-ansi) ANSI output
  -n, --no-interaction  Do not ask any interactive question
  -v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug