You are not logged in.

#1 2023-03-04 15:42:15

Fitz
Member
Registered: 2023-03-04
Posts: 6

Alacritty Config Error

I'm fairly new to Alacritty as well as Linux i was trying to change my Alacritty font to 'Hurmit NF ' ,i followed all the required steps but for some reason Alacritty is throwing  (Unable to load config "/home/fitz/.config/alacritty/alacritty.yml") : Config error: did not find expected <document start> at line 113 column 6.

Offline

#2 2023-03-04 16:09:48

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,378

Re: Alacritty Config Error

Post the config.

cat ~/.config/alacritty/alacritty.yml | curl -F 'file=@-' 0x0.st

nb. that yml is whitespace sensitive, so proper indentation matters.

Online

#3 2023-03-04 16:44:45

Fitz
Member
Registered: 2023-03-04
Posts: 6

Re: Alacritty Config Error

Offline

#4 2023-03-04 16:50:19

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,378

Re: Alacritty Config Error

Line 113 is

# font:

and the entire section is commented.
This is probably not the broken version of the config?

Online

#5 2023-03-04 16:56:09

Fitz
Member
Registered: 2023-03-04
Posts: 6

Re: Alacritty Config Error

no its not, i just commented back the lines because alacritty was throwing errors

Offline

#6 2023-03-04 17:03:23

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,378

Re: Alacritty Config Error

Yeah… since it's a syntax error, the broken file is all that matters here.

Online

#7 2023-03-04 17:05:41

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,471
Website

Re: Alacritty Config Error

We need to see the version of the config file that resulted in errors.

It's notable that there is a "# " before descriptive comment lines and just a single "#" before the token of any commented out config entries except for "# font".  If you added just the "#" there, and there was already a leading space, this could be the problem.  But this is fairly wild speculation without seeing the config that actually caused the error.

EDIT: Actually I guess this space is also in a few related tokens - all the ones you most likely were editing - so perhaps this is a red-herring.

Last edited by Trilby (2023-03-04 17:07:17)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#8 2023-03-04 17:13:01

Fitz
Member
Registered: 2023-03-04
Posts: 6

Re: Alacritty Config Error

sry my bad i didn't look correctly.. i apologize
here's the correct file : http://0x0.st/HzwZ.txt

Offline

#9 2023-03-04 17:14:40

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,471
Website

Re: Alacritty Config Error

So my speculation was actually spot on.  So you have the solution, right?

As was seth's

seth wrote:

nb. that yml is whitespace sensitive, so proper indentation matters.

Last edited by Trilby (2023-03-04 17:15:33)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#10 2023-03-04 17:34:47

Fitz
Member
Registered: 2023-03-04
Posts: 6

Re: Alacritty Config Error

i think i indented everything right and also looked some other people configs, it still is giving errors

Offline

#11 2023-03-04 17:41:55

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,378

Re: Alacritty Config Error

Not in the config you posted.
You cannot have leading blanks and the blank count between levels needs to be constent (whether it's 2, 3 or 4 blanks per level, but it needs to be alwas the same)

Online

#12 2023-03-04 17:45:44

Fitz
Member
Registered: 2023-03-04
Posts: 6

Re: Alacritty Config Error

fixed now, thanks guys...

Offline

#13 2023-03-04 19:30:50

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,378

Re: Alacritty Config Error

Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.

Online

Board footer

Powered by FluxBB