apexatoll / aoc-cli

Command line interface for Advent of Code, built in Ruby using Kangaru
MIT License
55 stars 2 forks source link

Error when initializing year #1

Closed mortenscheel closed 3 years ago

mortenscheel commented 3 years ago

Hi.

When I run aoc -y 2020 to initialize the year, I get this error:

no implicit conversion from nil to integer

I'm on Mac, with Ruby from Homebrew (ruby 3.0.0p0 (2020-12-25 revision 95aff21468) [x86_64-darwin20]) I've tried running the command in both zsh and bash. Have tried both gem and manual install. The session token is stored in ~/.config/aoc-cli

apexatoll commented 3 years ago

This error likely means your session key is not set properly, I could reproduce this error using a bogus key I typed at random into my config file

If you go into ~/.config/aoc-cli/aoc.rc you should see the key under the format

cookie=>your_alias=>your_key

The key should start with session= and there should be no spaces between anything

mortenscheel commented 3 years ago

Thanks. I had just add the session id without the session= prefix.

apexatoll commented 3 years ago

No problem, I will be adding some better key validation in the next version