Ubuntu 19.04 on HP Spectre x360 13-4110nl

PUBLISHED ON APRIL 26, 2019 — HARDWARE, LINUX

Fix airplane mode

Right after login into GNOME, airplane mode starts to cycle on and off on its own will for about 10 seconds, which is super annoying. To fix that, use the workaroung suggested in this Stackoverflow answer:

sudo vi /etc/systemd/system/hp-keycodes.service
[Unit]
Description=HP setkeycodes fix
# credits: https://askubuntu.com/questions/965595/why-does-airplane-mode-keep-toggling-on-my-hp-laptop-in-ubuntu-18-04/965596#965596

[Service]
Type=oneshot
Restart=no
RemainAfterExit=no
ExecStart=/usr/bin/setkeycodes e057 240 e058 240

[Install]
WantedBy=rescue.target
WantedBy=multi-user.target
WantedBy=graphical.target
sudo systemctl daemon-reload
sudo systemctl enable hp-keycodes.service
sudo reboot

Telegram

Telegram can be installed via Snap.

To autostart it on login, open “Startup applications” and create a new entry with the following command:

/usr/bin/snap run telegram-desktop -startintray

Dual booting with Windows

To make GRUB remember the last booted OS between Ubuntu and Windows, put the following in /etc/default/grub:

GRUB_DEFAULT=saved
GRUB_SAVEDEFAULT=true

Then run:

sudo update-grub

Set VIM full as editor

VIM full has full syntax highlighting support enabled by default. Install it:

sudo apt install vim

Set it as one of the possible editors

sudo update-alternatives --install /usr/bin/editor editor /usr/bin/vim 100

Finally set it as the current editor:

sudo select-editor

Select /usr/bin/vim.

TAGS: LINUX, UBUNTU