jmacdonald / amp

A complete text editor for your terminal.

Home Page:https://amp.rs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Incorrect parsing of config.yml file leads to a black screen.

sjmackenzie opened this issue · comments

Steps to reproduce:

  • $ cargo install amp (installs amp = "0.5.2" using beta or nightly)
  • $ ~/.cargo/bin/amp .
  • $ edit the config file (can see everything just fine)
  • <shft>-q
  • reopen amp

Expected behaviour

  • can see the editor

Actual behaviour

  • totally blank terminal tab, commands seem to work as <shft>-q exits and the editor edits and saves files.

System conf

  • NixOS

Further notes:

I worry I might have mistyped something in the config file and amp sulked.

  1. where is the default config.yaml file normally
  2. have you seen this issue before.

Update

okay the problem was theme: solazized_dark (note the spelling mistake) in the ~/.config/amp/config.yml file. Might be good to have more robust parsing of the yaml file.

Hi @sjmackenzie! Thanks for filing this bug. 🙂

Looks like this line is to blame. We should be falling back to a default theme if a custom one can't be found, and only raising an error if the fallback fails.