Issue with alacritty migrate

Hello again! I’ve got an issue with alacritty migrate.

sudo alacritty migrate

Configuration file migration failed:
    "/root/.config/alacritty/alacritty.toml": already in TOML format

If I reopen alacritty it still says the same warning

YAML config “/home/user/.config/alacritty/alacritty/yml” is deprecated, please migrate to TOML unsing ‘alacritty migrate’

when I those
it gets replaceed by the following error message

[ERROR]
($ALACRITTY_LOG) :
unable to loead config
“/home/user/.config/alacritty/alacritty.yml” : Config error : duplicate entry with key “window” at line 6 column 1

micro ~/.config/alacritty/alacritty.yaml
shows the env: entry at line 6
and the toml file does not exist at all.

[🔴] × garuda-inxi
System:
  Kernel: 6.7.5-zen1-1-zen arch: x86_64 bits: 64
    compiler: gcc v: 13.2.1 clocksource: tsc avail: acpi_pm
    parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen
    root=UUID=48637f32-6542-4b8d-9034-f859ede8855e rw
    rootflags=subvol=@ quiet rd.udev.log_priority=3
    vt.global_cursor_default=0
    systemd.unified_cgroup_hierarchy=1
    resume=UUID=73407c84-654f-4dc0-9a0c-af4b77f8503c
    loglevel=3 ibt=off
  Desktop: Xfce v: 4.18.1 tk: Gtk v: 3.24.36 wm: bspwm
    v: 0.9.10 with: xfce4-panel tools: avail: xautolock vt: 7
    dm: LightDM v: 1.32.0 Distro: Garuda base: Arch Linux
Machine:
  Type: Laptop System: Hewlett-Packard product: HP
    EliteBook Folio 9480m v: A3009DD10303
    serial: <superuser required> Chassis: type: 10
    serial: <superuser required>
  Mobo: Hewlett-Packard model: 22DA v: KBC Version 92.15
    serial: <superuser required> part-nu: K6E26UC#ABD
    uuid: <superuser required> UEFI: Hewlett-Packard
    v: M85 Ver. 01.33 date: 10/27/2015
Battery:
  ID-1: BAT0 charge: 30.8 Wh (95.1%)
    condition: 32.4/32.4 Wh (100.0%) volts: 16.4 min: 14.8
    model: Hewlett-Packard Primary type: Li-ion
    serial: <filter> status: not charging
CPU:
  Info: model: Intel Core i7-4600U bits: 64 type: MT MCP
    arch: Haswell gen: core 4 level: v3 note: check
    built: 2013-15 process: Intel 22nm family: 6
    model-id: 0x45 (69) stepping: 1 microcode: 0x26
  Topology: cpus: 1x cores: 2 tpc: 2 threads: 4
    smt: enabled cache: L1: 128 KiB
    desc: d-2x32 KiB; i-2x32 KiB L2: 512 KiB
    desc: 2x256 KiB L3: 4 MiB desc: 1x4 MiB
  Speed (MHz): avg: 2096 high: 2097 min/max: 800/3300
    scaling: driver: intel_cpufreq governor: performance
    cores: 1: 2096 2: 2097 3: 2095 4: 2096 bogomips: 21550
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1
    sse4_2 ssse3
  Vulnerabilities: <filter>
Graphics:
  Device-1: Intel Haswell-ULT Integrated Graphics
    vendor: Hewlett-Packard driver: i915 v: kernel
    arch: Gen-7.5 process: Intel 22nm built: 2013 ports:
    active: eDP-1 empty: DP-1, DP-2, HDMI-A-1, HDMI-A-2
    bus-ID: 00:02.0 chip-ID: 8086:0a16 class-ID: 0300
  Device-2: Chicony HP HD Webcam driver: uvcvideo
    type: USB rev: 2.0 speed: 480 Mb/s lanes: 1 mode: 2.0
    bus-ID: 2-7:5 chip-ID: 04f2:b477 class-ID: 0e02
    serial: <filter>
  Display: x11 server: X.Org v: 21.1.11 compositor: Picom
    v: git-c4107 driver: X: loaded: intel
    unloaded: modesetting alternate: fbdev,vesa dri: i965
    gpu: i915 display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1366x768 s-dpi: 96
    s-size: 361x203mm (14.21x7.99") s-diag: 414mm (16.31")
  Monitor-1: eDP-1 mapped: eDP1
    model: ChiMei InnoLux 0x14a4 built: 2014 res: 1366x768
    hz: 60 dpi: 112 gamma: 1.2 size: 310x170mm (12.2x6.69")
    diag: 355mm (14") ratio: 16:9 modes: 1366x768
  API: Vulkan v: 1.3.276 layers: 3 device: 0
    type: integrated-gpu name: Intel HD Graphics 4400 (HSW
    GT2) driver: mesa intel v: 24.0.1-arch1.1
    device-ID: 8086:0a16 surfaces: xcb,xlib device: 1
    type: cpu name: llvmpipe (LLVM 16.0.6 256 bits)
    driver: mesa llvmpipe v: 24.0.1-arch1.1 (LLVM 16.0.6)
    device-ID: 10005:0000 surfaces: xcb,xlib
  API: OpenGL Message: Unable to show GL data. glxinfo
    is missing.
Audio:
  Device-1: Intel Haswell-ULT HD Audio
    vendor: Hewlett-Packard driver: snd_hda_intel v: kernel
    bus-ID: 00:03.0 chip-ID: 8086:0a0c class-ID: 0403
  Device-2: Intel 8 Series HD Audio
    vendor: Hewlett-Packard 8 driver: snd_hda_intel v: kernel
    bus-ID: 00:1b.0 chip-ID: 8086:9c20 class-ID: 0403
  API: ALSA v: k6.7.5-zen1-1-zen status: kernel-api
    tools: alsactl,alsamixer,amixer
  Server-1: JACK v: 1.9.22 status: off tools: N/A
  Server-2: PipeWire v: 1.0.3 status: off tools: pw-cli
  Server-3: PulseAudio v: 17.0 status: active with:
    1: pulseaudio-alsa type: plugin 2: pulseaudio-jack
    type: module tools: pacat,pactl,pavucontrol
Network:
  Device-1: Intel Ethernet I218-LM vendor: Hewlett-Packard
    driver: e1000e v: kernel port: 5080 bus-ID: 00:19.0
    chip-ID: 8086:155a class-ID: 0200
  IF: enp0s25 state: down mac: <filter>
  Device-2: Intel Wireless 7260 driver: iwlwifi v: kernel
    pcie: gen: 1 speed: 2.5 GT/s lanes: 1 bus-ID: 08:00.0
    chip-ID: 8086:08b1 class-ID: 0280
  IF: wlo1 state: up mac: <filter>
  Info: services: NetworkManager, systemd-timesyncd,
    wpa_supplicant
Bluetooth:
  Device-1: Intel Bluetooth wireless interface
    driver: btusb v: 0.8 type: USB rev: 2.0 speed: 12 Mb/s
    lanes: 1 mode: 1.1 bus-ID: 2-4:3 chip-ID: 8087:07dc
    class-ID: e001
  Report: btmgmt ID: hci0 rfk-id: 0 state: down
    bt-service: enabled,running rfk-block: hardware: no
    software: yes address: <filter> bt-v: 4.0 lmp-v: 6
    status: discoverable: no pairing: no
Drives:
  Local Storage: total: 238.47 GiB used: 56.13 GiB (23.5%)
  SMART Message: Required tool smartctl not installed.
    Check --recommends
  ID-1: /dev/sda maj-min: 8:0 vendor: SanDisk
    model: SD7TB3Q-256G-1006 size: 238.47 GiB block-size:
    physical: 4096 B logical: 512 B speed: 6.0 Gb/s
    tech: SSD serial: <filter> fw-rev: 0306 scheme: GPT
Partition:
  ID-1: / raw-size: 229.42 GiB size: 229.42 GiB (100.00%)
    used: 56.13 GiB (24.5%) fs: btrfs dev: /dev/sda2
    maj-min: 8:2
  ID-2: /boot/efi raw-size: 256 MiB
    size: 252 MiB (98.46%) used: 570 KiB (0.2%) fs: vfat
    dev: /dev/sda1 maj-min: 8:1
  ID-3: /home raw-size: 229.42 GiB
    size: 229.42 GiB (100.00%) used: 56.13 GiB (24.5%)
    fs: btrfs dev: /dev/sda2 maj-min: 8:2
  ID-4: /var/log raw-size: 229.42 GiB
    size: 229.42 GiB (100.00%) used: 56.13 GiB (24.5%)
    fs: btrfs dev: /dev/sda2 maj-min: 8:2
  ID-5: /var/tmp raw-size: 229.42 GiB
    size: 229.42 GiB (100.00%) used: 56.13 GiB (24.5%)
    fs: btrfs dev: /dev/sda2 maj-min: 8:2
Swap:
  Kernel: swappiness: 133 (default 60)
    cache-pressure: 100 (default) zswap: no
  ID-1: swap-1 type: zram size: 7.64 GiB
    used: 1.52 GiB (19.8%) priority: 100 comp: zstd
    avail: lzo,lzo-rle,lz4,lz4hc,842 max-streams: 4
    dev: /dev/zram0
  ID-2: swap-2 type: partition size: 8.8 GiB
    used: 0 KiB (0.0%) priority: -2 dev: /dev/sda3
    maj-min: 8:3
Sensors:
  System Temperatures: cpu: 42.0 C mobo: N/A
  Fan Speeds (rpm): N/A
Info:
  Memory: total: 8 GiB available: 7.64 GiB
    used: 3.94 GiB (51.6%)
  Processes: 240 Power: uptime: 19h 27m
    states: freeze,mem,disk suspend: deep avail: s2idle
    wakeups: 0 hibernate: platform avail: shutdown,
    reboot, suspend, test_resume image: 3.02 GiB
    services: upowerd,xfce4-power-manager Init: systemd
    v: 255 default: graphical tool: systemctl
  Packages: pm: pacman pkgs: 1484 libs: 442
    tools: pamac,paru Compilers: clang: 16.0.6 gcc: 13.2.1
    Shell: garuda-inxi default: fish v: 3.7.0
    running-in: alacritty inxi: 3.3.33
Garuda (2.6.23-1):
  System install date:     2021-09-03
  Last full system update: 2024-02-20 ↻
  Is partially upgraded:   No
  Relevant software:       timeshift NetworkManager mkinitcpio
  Windows dual boot:       No/Undetected
  Failed units:

also tried the migrate -i option with and without sudo

λ alacritty migrate -i
Configuration file migration failed:
    "/home/user/.config/alacritty/alacritty.yml": parsing error: Config error: duplicate entry with key "window" at line 6 column 1
 sudo alacritty migrate -i
[sudo] password for user:
Configuration file migration failed:
    "/root/.config/alacritty/alacritty.toml": already in TOML format

thank you very for the awesome support!
best regards
algori

You have to execute it without sudo.
Before that, check what you have in

/home/user/.config/alacritty/alacritty.yml

at line 6
Ops, sorry, I see you already mentioned that.
But what does it mean

The toml file does not exist because you executed the migration only with sudo, for the root user instead of your user, and without sudo you get the error and the migration does not complete.

One thing you could do is to try resetting alacritty to its default config before launching alacritty migrate again. It should be:

cp /etc/skel/.config/alacritty/alacritty.yml ~/.config/alacritty/alacritty.yml

Make sure to backup your current ~/.config/alacritty/alacritty.yml before that.

Last but not least, it looks like you’re not alone with troubles with this migration.
This is a long issue regarding its implementation. closed but still quite “active”.

5 Likes

It’s just

alacritty migrate

nothing more or less.
Like the hint wrote

Works fine here on many DE’s.

Search for root files in your home folder

find $HOME ! -user $USER -type f

and remove them

sudo chown -R $USER: $HOME
4 Likes

Hello!

First of all, thank you for this quick reply, and I’m really sorry, but I have a big flaw, I’m stupid, when it comes to find information due to the internet.

so after a while of just getting useless topics and information, I still don’t know how to back up a file.
I’ve guessed just cp wouldn’t do the trick caused by the name of the file. but maybe I just have to change the name a bit while coping, but even this command I could’t find.

embarrassed regards
algori

You can back up the file with cp, for example like this:

cp ~/.config/alacritty/alacritty.yml ~/.config/alacritty/alacritty.yml.backup

In this example, ~/.config/alacritty/alacritty.yml is the file to be copied, and ~/.config/alacritty/alacritty.yml.backup is the name of the copy.

5 Likes

I guess there is no /etc/skel/… anymore, caused by the new version. cp didn’t found it.

thank you!

well, this is how it goes, I knew what this is about, but wasn’t confident enough to just do it, or even read about the cp commad. sorry for that extra effort!

no I’m just a little weird headed lately, cp does those and nothing else.sorry for fetching my own tail. (gotta cold)

I would guess the one in /etc/skel is no longer a yml file, so you might have to change that command accordingly. Check like this:

ls /etc/skel/.config/alacritty/
1 Like

your solution I actually didn’t get at all.

Sorry.

I’ve got, that it may does cause problems to have this sudo /root/.config/alacritty/alacritty.toml
file somewhere so I should remove the sudo ownership?

and thats what the -R is causing, I guess.

but the find command does not do something usefull for me. I might change the path wrong, or the user command. I’ll look it up.

(I tried the migrate without sudo first.)

there isn’t anything about alacritty

 /etc/skel/.config🔒 took 1ms
 ╰─λ ls
drwxr-xr-x    - root 19 Feb 19:28  autostart
drwxr-xr-x    - root 19 Feb 19:28  bleachbit
drwxr-xr-x    - root 19 Feb 19:28  deluge
drwxr-xr-x    - root 19 Feb 19:28  environment.d
drwxr-xr-x    - root  7 Mai  2021  falkon
drwxr-xr-x    - root 19 Feb 19:28  fish
drwxr-xr-x    - root  7 Mai  2021  libreoffice
drwxr-xr-x    - root 19 Feb 19:28  micro
drwxr-xr-x    - root 19 Feb 19:28  mpv
drwxr-xr-x    - root 19 Feb 19:28  pacseek
drwxr-xr-x    - root 19 Feb 19:28  psd
drwxr-xr-x    - root 19 Feb 19:28  smplayer
drwxr-xr-x    - root 19 Feb 19:28  vlc
.rw-r--r-- 2,3k root 12 Feb  2022  starship.toml

That makes sense actually, since Alacritty is not a default package for XFCE or for Garuda common settings.

Do you have a lot of custom configuration in your Alacritty config? If not, it might be easier to just pull down a new config by moving the yml one to backup and re-open Alacritty.

To do that, you would do basically the same command as the copy example above except use mv instead of cp.

mv ~/.config/alacritty/alacritty.yml ~/.config/alacritty/alacritty.yml.backup

When you re-open Alacritty, it should generate a new config on it’s own. I am assuming it would do this with a toml config since that is the new supported standard.

From there, it would be a matter of pulling over any customization you want to keep from the yml version into the toml version.

2 Likes

thank you it worked just fine!
hm, maybe not perfectly fine. no errors and warnings, but it seems like it’s still not in toml.
or it is and I just don’t find the config file.

found it! it is still root
/root/.config/alacritty/alacritty.toml

but if I change anything in that file, and save, nothing is different.

didn’t had a lot customized, just some color schemes.

best regards thankfully
algori

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