Terminal issue : failed to parse JSON config file

Hi folks,

When i open the terminal i have this error on top of the window :

Error: failed to parse JSON config file /usr/share/fastfetch/presets/dr460nized at (1, 2): no digit after minus sign

This message replace the logo and the system settings information in the terminal window

I have opened the config file and it looks like that :

--kitty /usr/share/icons/garuda/dr460nized-fastfetch.png
--logo-width 36
--structure Title:Separator:OS:Host:Kernel:Uptime:Battery:Break:Packages:Shell:Resolution:Terminal:Break:CPU:GPU:Memory:Break:Colors
--host-format "{/2}{-}{/}{2}{?3} {3}{?}"
--battery-format "{/4}{-}{/}{4}%{?5} [{5}]{?}"
--gpu-key "GPU"

As @nepti suggered i enter the following command in the terminal and force the update :

sudo pacman -S fastfetch

It update the file but the issue is still present.

The content is incorrect/outdated.

Open /usr/share/fastfetch/presets/dr460nized.jsonc with an editor and delete the entire content. Then insert this:

{
  "$schema": "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json",
  "logo": {
    "type": "kitty",
    "source": "/usr/share/icons/garuda/dr460nized-fastfetch.png",
    "width": 36
  },
  "modules": [
    "title",
    "separator",
    "os",
    {
      "type": "host",
      "format": "{/2}{-}{/}{2}{?3} {3}{?}"
    },
    "kernel",
    "uptime",
    {
      "type": "battery",
      "format": "{/4}{-}{/}{4}%{?5} [{5}]{?}"
    },
    "break",
    "packages",
    "shell",
    "terminal",
    "break",
    "cpu",
    {
      "type": "gpu",
      "key": "GPU"
    },
    "memory",
    "break",
    "colors"
  ]
}

save and close the editor. Then it should work again.

6 Likes

The reason for this error is you have to manually migrate the old fastfetch format file into a new format (JSONC or JSON, both work). This is a recent change fastfetch made, not Garuda.

There are other threads explaining this on the forum if you need more details.

6 Likes

Awesome @nepti !
It’s working normally after i followed your guide. The message disappear and the Garuda logo and the system informations are back.
Thank you so much for your help and your support <3

1 Like

Many thanks @FGD for the explanation :slight_smile:
Thank you for your support !

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.