Skip to main content

Advent of Code CLI with leaderboard integration and code quality grading

Project description

AOC CLI

Advent of Code CLI with leaderboard integration.

Installation

cd packages/cli-py
pip install -e .

Usage

Initialize configuration

aoc init

You'll be prompted for:

  • Email, display name, AoC session token
  • Language (press Enter for Python, the only built-in template)

This creates:

  • ~/.aocconfig - Your configuration
  • aoc/templates/python.py - Customizable solution template
  • aoc/<year>/ - Directory for your solutions

Note: Only Python is supported out of the box. For other languages, create your own template at aoc/templates/<language>.<ext>.

Get puzzle input

aoc get 2024/1

This will:

  • Download your puzzle input to in.txt
  • Copy your template to solution.*
  • Extract a test case to test.txt (auto-parsed—verify manually)
  • Register start time with the server
  • Open the puzzle in your browser

Note: Only one test case is extracted. The expected answer is auto-parsed and may be incorrect.

Run solution with real input

aoc run
# or
aoc run -p 2024/1

Run solution against test cases

aoc test
# or
aoc test -p 2024/1

The expected output shown is auto-parsed from the problem page—always verify it's correct.

Submit answer

aoc submit
# or
aoc submit -a 12345
# or
aoc submit -p 2024/1 -a 12345

The answer is parsed from the last line of your solution's stdout. The CLI will show you what it parsed—verify it's correct before submission.

Solution Requirements

Your solution must:

  1. Read input from in.txt
  2. Print the final answer as the last line to stdout

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

anindit_aoc_cli-1.0.1.tar.gz (10.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

anindit_aoc_cli-1.0.1-py3-none-any.whl (16.0 kB view details)

Uploaded Python 3

File details

Details for the file anindit_aoc_cli-1.0.1.tar.gz.

File metadata

  • Download URL: anindit_aoc_cli-1.0.1.tar.gz
  • Upload date:
  • Size: 10.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.6

File hashes

Hashes for anindit_aoc_cli-1.0.1.tar.gz
Algorithm Hash digest
SHA256 35127c40644c56bd0a687e8008810e3c17d9c81dcc88f78ea2add86b838d2cdf
MD5 2176c1aee5b94516fccca879aa874e8b
BLAKE2b-256 5039fcd3ac92b387ce2489c040ec23ef86e3cdf215fa45f598b200010cd3e2ac

See more details on using hashes here.

File details

Details for the file anindit_aoc_cli-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for anindit_aoc_cli-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3f7bc834a75cc82c35a6164cf475b69605cf63198743129f86672478488c94cf
MD5 7902351ad978fbc9e39677a270d0d0ff
BLAKE2b-256 e0ae02b34f2354e38086ab5f40a1d29db018930e110202f1036863646731899d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page