For laptop user, there could be a quite annoying issue that the ‘Airplane Mode’ automatically turns on when lid closed, or when the screen is tilted sideways.
For HP laptops running Ubuntu, Fedora, or other Linux using systemd, there’s a workaround by mapping the HP e057 and e058 scancodes to 240 (no-op key). So it won’t automatically turn on Airplane Mode, while the option in ‘Wi-Fi’ settings and fn + F12 key combination still function.
NOTE: This tutorial is tested and works in my Ubuntu 22.04 on HP 246 laptop. It may or may not work in your machine.
1. Create service to remap the scancode:
1.) Firstly, press Ctrl+Alt+T on keyboard to open terminal. When it opens, run command to create a service file and edit via Gedit text editor:
Depends on your desktop environment, replace gedit in command with your system text editor (e.g., gnome-text-editor for Ubuntu 22.10+/Fedora workstation), or use nano command line editor that works in most Linux. When file opens, paste below lines and save it.
JetBrains announced the 2022.1 release of its PyCharm IDE few days ago. Here’s how to install in Ubuntu in different ways.
What’s New in PyCharm 2022.1
This is the first release of the IDE in 2022. Release highlights include (see release note for details):
Basic http authentication support for custom package repositories
Enhanced code completion for TypedDict
Improved TypedDict per-key warnings
Run commands directly from Markdown files
New Copy code snippet for Markdown.
Code cells remain in Edit mode after execution (Pro)
Optimized cell copy-pasting (Pro)
MongoDB: Editing fields in results (Pro)
New Services UI for Docker (Pro)
How to Install PyCharm 2022.1 in Ubuntu Linux
Method 1: Snap package
JetBrains provides official package for Ubuntu users through the Snap which runs in sandbox. Ubuntu user may just search for and install it from Ubuntu Software:
For choice, you may also press Ctrl+Alt+T on keyboard and run commands below to install it:
sudo snap install pycharm-community --classic
And you may replace pycharm-community with pycharm-professional in command for pro edition.
Method 2: Flatpak package
The IDE is also available to install as Flatpak, another universal package runs in sandbox.
1. First press Ctrl+Alt+T on keyboard and run command to install Flatpak daemon:
sudo apt install flatpak
2. Next, install the Python IDE as Flatpak using command:
Want to play some nature sounds or ambient noise on Linux? Blanket is a really good choice with a stylish user interface.
As far as know, there are 2 good open-source applications in Linux for playing ambient sounds. They are ‘Blanket‘ who has a good design on its UI, and ‘Anoise‘ which has many more cool sounds but looks ugly.
For Ubuntu 22.04, Fedora 36 or Arch Linux user with GNOME 42, Blanket looks more native because of the dark mode support and GTK4 + libadwaita port.
As you see in the picture, it can play some nature sounds including Rain, Storm, Wind, Waves, Stream, Birdsong, Summer Night, as well as a few travels, coffee shop, and other noises.
The app starts playing either by clicking on a sound icon or moving the volume control slider. It supports multiple sounds playback. All playing sound icons are highlighted. By clicking on the icons can mute/un-mute them, though there’s a global start/stop button in the top-left.
Though it has only more than a dozen of sounds, there’s “Add Custom Sounds” button in the bottom to add your own sounds. And, it supports presets and can run in background and control via the Clock menu button.
Install Blanket in Ubuntu & other Linux:
Method 1: Install Blanket via universal Flatpak
The app is available to install as Flatpak for most Linux. Just follow the official setup guide.
For Ubuntu, press Ctrl+Alt+T on keyboard to open terminal and run command to install the daemon:
This simple tutorial shows how to install Google Earth Pro or Enterprise Client in Ubuntu 22.04 step by step.
Today we can use Google Earth easily in web browser or mobile phone. For those still need a desktop app, Google’s official apt repository provides the .deb packages for Debian/Ubuntu Linux.
1. Setup the key:
To add the Google Earth repository, you need to first install the key so your Ubuntu will trust the package from that repository.
To do so, press Ctrl+Alt+T on keyboard to open terminal and run the command below:
This is a single command that download the key file, dearmor it, and install as ‘earth.gpg’ file under ‘/etc/apt/trusted.gpg.d’ to follow the new Debian policy.
In case the command STUCK at blinking cursor, type user password (no visual feedback) and hit Enter for sudo authentication. And it should finally output un-readable messy code.
2. Add Google Earth repository:
After setup the key, run the command below will add the Google Earth apt repository into your system:
This command will create google.list file under ‘/etc/apt/sources.list.d’ directory, and write the line “deb [arch=amd64] http://… main” (without quotes) into that file.
3. Install Google Earth
Finally, refresh system package cache via command:
sudo apt update
And, then install the application by running command:
sudo apt install google-earth-pro-stable
You may replace google-earth-pro with google-earth-ec for Enterprise Client
After installation, search for and launch it from ‘Activities’ overview screen and enjoy!
Remove Google Earth and its repository
After installed the package, it setup the apt repository again so you’ll get duplicated warning next time you run apt update.
To fix it, launch “Software & Updates” and remove one of the sources under “Other Software” tab.
Or remove all of them if you don’t want to get updates from the repository any more.
And to remove the Google Earth package, run the command below in terminal (Ctrl+Alt+T):
For Linux users want to configure the boot menu screen, Grub Customizer is always a good choice for beginners.
I’ve written quite a few tutorials about the default boot-loader, which is called Grub, including set default OS to boot, install themes, add kernel parameters for hibernate, custom screen resolution, etc. All of them can be done via Grub-Customizer besides editing the configuration file.
Grub Customizer – Set default entry, menu visibility, & Kernel parameters
Why Grub Customizer Removed from Ubuntu Repository:
Grub Customizer is removed from Ubuntu 22.04 repository due to its broken logic issue. See this bug for details
However, there are some customizations that are apparently not doable by simply editing the existing configuration scripts. For those, the program moves all existing conf scripts out of the way, and instead installs “proxy scripts” written in a custom language that basically filter the output of the original scripts…
In general, Grub Customizer works for what it does, but it has logic issue about how it do the customizations that might cause issues (especially for upgrading system). So Ubuntu developer team remove the package from the universe repository.
How to Install Grub Customizer via PPA in Ubuntu 22.04/24.04
The software developer has updated the app claimed that the bug mentioned above has been fixed. And, the package has been published in its official Ubuntu PPA.
1. Add Grub Customizer PPA
Firstly, press Ctrl+Alt+T on keyboard to open terminal. When it opens, run the command below to add the PPA:
Type user password when it asks (no asterisk feedback), then hit Enter to continue.
2. Add Grub Customizer PPA
After adding the PPA, you may run the apt command to install the tool in Ubuntu:
sudo apt install grub-customizer
NOTE: For Ubuntu based system, it may need to run sudo apt update to update package cache first.
Once installed, click on top-left ‘Activities‘ then search for and open the tool.
Configuring boot menu requires root (administrator) permission, so it will ask for password authentication on app start.
In the first tab, you may edit the text to display, add, remove, and/or re-arrange the menu entries.
For dual-boot or multi-boot machine, it’s possible to select which entry as default under General settings page. There are as well menu visibility and kernel parameters options (see the first screenshot).
Just like editing ‘/etc/default/grub‘ files, the bottom-right ‘advanced settings‘ button adds ability to add/edit/remove more rules.
And, ‘Appearance settings’ page offers options to configure text font, background, themes etc. Though, I prefer to install themes directly via source tarball (find Grub Themes here).
After configuration, remember to click ‘save‘ button to apply changes. That’s all.
This simple tutorial shows how to enable Secure Shell (SSH) in Ubuntu 22.04, so you can login remotely and transfer data securely via the cryptographic network protocol.
Ubuntu uses OpenSSH to provide Secure Shell services. The client is pre-installed with out-of-the-box support for connecting to remove SSH server. The server package is available in system repository but not installed by default.
1. Install SSH Server:
Firstly, connect to your Ubuntu server, or press Ctrl+Alt+T on keyboard to open terminal in Ubuntu desktop.
When it opens, run the command below to install the server package:
sudo apt install ssh
Type user password for sudo authentication, though there’s no asterisk feedback
Once installed the service should run automatically. If not, use commands below to enable and start it:
After step 1, you should be able to connect to this Ubuntu server or desktop remotely via ssh and/or scp commands.
You may however configure it to listen on a different port, specify which users allowed to login, change the authentication methods, etc.
To do so, edit the “/etc/ssh/sshd_config” via the command below:
sudo nano /etc/ssh/sshd_config
For Ubuntu Desktop, replace nano with gedit to edit the config file with a graphical interface.
When the file opens, by removing ‘#‘ at the beginning and changing the number after ‘Port’ will change the listening port; Enable “PermitRootLogin prohibit-password” (remove # at the beginning will enable it) will allow root login via authentication key. To allow password login, change the value to ‘yes’, and you need to enable “PasswordAuthentication yes”.
For more configurations, see this document. And, if you want to setup an authentication key to login without password, try this tutorial.
After saving the file, remember to restart the SSH service to apply changes:
sudo systemctl restart sshd
3. Login or transfer data via SSH:
After setup the remote SSH server, you may run the command below to login remotely:
ssh server_user@server_ip -p 22890
Change the port number 22890 to yours or skip the -p flag if the default port is in use.
And, copy data from local to server via scp command:
This simple tutorial shows how to hide user list and/or enable touchpad tap clicking in login screen of Ubuntu 22.04 LTS.
GNOME, the default desktop environment, has some hidden keys to configure the login screen options. However, you need gdm (Gnome Display Manager) user privilege who handles the default login.
After following this tutorial, Ubuntu will no longer display usernames in login screen. Instead, you need to manually type user-name and then password to login.
Option 1: Single command to hide user list from login screen
Firstly press Ctrl+Alt+T keyboard shortcuts to open terminal. When it opens, run the commands below as you need.
1.) Install dbus-x11 inter-process messaging system by running command:
sudo apt install dbus-x11
Without the package, you’ll get following output when running command in step 2.) to hide user list or enable tap to click.
dconf-WARNING **: 15:23:16.101: failed to commit changes to dconf: Failed to execute child process “dbus-launch” (No such file or directory)
2.) To hide your usernames from login screen, use command:
So far, it’s AppImage package that works on most Linux!
2.) Right-click on the ‘AppImage’ package, and open its “Properties” dialog. Then enable ‘Allow executing file as program‘ under Permissions tab. Finally, right-click and select run it to launch the tool.
3.) When it opens, enable ‘tap-to-click’ under Touchpad tab, and disable user list under Miscellaneous.
After clicking ‘Apply’ and typing user password for authentication, you’ll see the changes in next login.
Want to open folder or edit file as administrator (aka root in Linux)? Here’s how to do the trick by adding menu option in Ubuntu 22.04 file manager.
The ‘Files’ (aka nautilus) has an extension called nautilus-admin to do administrative operations. With it, you may right-click on folder and select “Open as Administrator“, or right-click on file and select “Edit as Administrator“.
Don’t like MS Windows, it however does not support running an app as root.
1. Open Terminal
Firstly, open terminal either by pressing Ctrl+Alt+T key combination on keyboard, or by searching from the ‘Activities’ overview screen.
2. Install nautilus-admin
When the terminal opens, paste the command below into it and hit Enter.
sudo apt install nautilus-admin
Type user password (no asterisk feedback) for sudo authentication and hit Enter to continue.
3. Apply change
Once installed the extension, you need to restart the file manager to apply change.
Not just close and re-open the file manager window, but you need to run command to quit the background service and let it start again automatically:
This simple tutorial shows how to install the tiny sound recording app “Audio Recorder” in Ubuntu 22.04 and Ubuntu 24.04 LTS.
“Audio Recorder” is a little open-source app that can record audio from your system’s sound card, microphone, browsers, webcams and any sound that your PC plays out.
The tool has a built-in timer that automates audio recording on given clock time or after time period, auto stop when the recorded file size exceeds a limit. And, it can be controlled via Rhythmbox, VLC, Audacious and other MPRIS2 compatible players. For Skype users, it can automatically record all your Skype calls without any user interaction.
Sounds can be saved as OGG audio, Flac, MP3, WAV, M4A, and OPUS. And, it has command line options to control app interface as well as recording actions.
Install Audio Recorder in Ubuntu 22.04:
The PPA also contains old version packages for Ubuntu 16.04, Ubuntu 18.04, and Ubuntu 20.04
The app has been more than 10 years old! The developer team maintains an official PPA with all Ubuntu releases and their derivatives (e.g., Linux Mint) support. Somehow, it does not available in Ubuntu’s universe repository.
1. Add the PPA
First press Ctrl+Alt+T on keyboard to open terminal. When it opens, paste the command below and hit Enter:
sudo add-apt-repository ppa:audio-recorder/ppa
Type user password (no asterisk feedback) for sudo authentication and hit enter to continue.
NOTE: For Ubuntu 24.04 and 23.10, the run command below to add this PPA instead.
After adding the PPA and updating the package cache (which is done automatically), just run the apt command below to install the tool:
sudo apt install audio-recorder
Some Ubuntu based systems need to run sudo apt update to manually refresh package cache after adding PPA. While it’s done automatically in Ubuntu.
Once installed, search for and open the tool from ‘Activities’ overview screen and enjoy!
How to Remove Audio Recorder:
To remove the Ubuntu PPA, either launch “Software & Updates” utility and remove the source from Other Software tab, or run the command below in terminal:
Ubuntu 22.04 finally removed the .deb package for Firefox web browser from it’s repository! Here’s how to install it back.
As you may know, Firefox in Ubuntu repository since 22.04 is a Snap package that runs in sandbox. It’s easy to remove it. But when you try installing the deb package via apt, it just install the Snap version back!!
Like Chromium, the Firefox deb in Ubuntu 22.04 + repository is an empty package that links to the Mozilla’s official Snap.
And, if you want to install the latest Firefox using the classic .deb package format, there are 2 easy ways:
Mozilla Team PPA maintained by Ubuntu Team members.
Mozilla’s new apt repository maintained by Firefox developer team!
(Optional) Remove the pre-installed Firefox Snap
It’s OK to keep the default Snap package. But it will cause duplicated Firefox icons after installing Firefox in .deb package format.
NOTE: Export bookmarks and backup other important data before removing it!
To remove it, press Ctrl+Alt+T on keyboard to open terminal. Then, run the command:
sudo snap remove firefox
Also, remove the empty Deb package by running command:
sudo apt remove firefox
Option 1: Install Firefox via “Mozilla Team” team PPA
The team described that it has assumed responsibility for Ubuntu’s official Firefox and Thunderbird packages.
And, the Firefox and Firefox ESR package maintainer for “Mozilla Team” team PPA, Rico Tzschichholz, is a well-known Ubuntu user who also maintains the official packages for LibreOffice, Plank dock, and unbound DNS server.
1. Add Mozilla Team PPA
In terminal (Ctrl+Alt+T), run the command below to add the PPA. Type user password (no asterisk feedback) when it asks and hit Enter to continue.
sudo add-apt-repository ppa:mozillateam/ppa
As the PPA description indicates, the PPA was previously created for Firefox ESR and Thunderbird. It now contains the latest Firefox too.
2. Set PPA priority:
The empty Firefox deb in Ubuntu’s official repository has version number 1:1snap1-0ubuntu2. It’s always higher than the PPA package version. Running package updates either via sudo apt upgrade or ‘Software Updater’ will automatically install the official one which redirects to Snap.
To workaround the issue, you have to set a higher PPA priority. To do so, run the command below in terminal (Ctrl+Alt+T):
sudo gedit /etc/apt/preferences.d/mozillateamppa
For Ubuntu 24.04, replace gedit in command with gnome-text-editor, or use nano that works in all the desktop environments.
The command creates and opens empty config file in Gedit text editor. When it opens, add the lines below and save it:
For nano text editor, press ctrl+s to save file, and ctrl+x to exit.
After saving the file, run sudo apt update command in terminal to apply changes.
sudo apt update
3. Install Firefox via apt
Tip: the commands in this step also installs Firefox for the old Ubuntu 16.04. Though sudo apt update need to be run first.
Finally, run the command below to install the latest Firefox package as deb:
sudo apt install firefox
Here -t 'o=LP-PPA-mozillateam' specifies to install Firefox from that PPA. It’s required until you set higher PPA package priority (see next step).
The -t 'o=LP-PPA-mozillateam' flag is no longer required after setup PPA priority.
For choice, you may install Firefox ESR instead. It’s another official Firefox package that moves slowly and targets for school or enterprise use.
sudo apt install firefox-esr
Option 2: Install Firefox via its official repository
Mozilla’s new apt repository contains 4 versions of Firefox packages: Firefox Stable, Firefox Beta, Firefox Development Edition, and Firefox Nightly. It’s a good choice for Ubuntu & Debian users.
1: Get Repository Key file
To add the new repository, you need to first download & install the key, so your system will trust the packages from it.
First, press Ctrl+Alt+T on keyboard to open terminal. When it opens, run command to make sure ‘/etc/apt/keyrings’ exist for storing the keys.
sudo mkdir -p /etc/apt/keyrings
Then, download & install the key by running the single command below in terminal:
wget -q https://packages.mozilla.org/apt/repo-signing-key.gpg -O- | sudo tee /etc/apt/keyrings/packages.mozilla.org.asc > /dev/null
After that, you can verify the new key file by listing the content of that directory via command ls /etc/apt/keyrings.
2: Add Mozilla’s apt repository
Also in a terminal window, run the single command below will create a config file and write the source repository.
echo "deb [signed-by=/etc/apt/keyrings/packages.mozilla.org.asc] https://packages.mozilla.org/apt mozilla main" | sudo tee /etc/apt/sources.list.d/mozilla.list > /dev/null
When done, you may verify by running cat /etc/apt/sources.list.d/mozilla.list to print the source file content.
3. Set apt repository priority:
Also you need to set higher priority for Mozilla’s repository, so Ubuntu will install Firefox from it rather than the snap package.
To do so, run command to create & edit the config file:
sudo gedit /etc/apt/preferences.d/mozilla
Also, replace gedit with gnome-text-editor for Ubuntu 24.04, or use nano command line editor that works in most desktop environments.
When file opens, add following lines and save it (For nano, press ctrl+s to save, and ctrl+x to exit).
Finally, refresh your system package cache by running command in terminal:
sudo apt update
And, install Firefox from that repository via command:
sudo apt install firefox
You may also use firefox-beta, firefox-devedition, or firefox-nightly in last command to install other versions.
How to Restore Firefox Snap:
To restore the pre-installed Snap package, or uninstall the .deb package, first remove the repositories:
To remove the Mozilla Team PPA, launch ‘Software & Updates‘ utility and navigate to Other Software tab, finally remove the corresponding source line.
To remove the Mozilla apt repository, simply delete the source file, by running command in terminal:
sudo rm /etc/apt/sources.list.d/mozilla.list
After that, either launch Software Updater to upgrade Firefox or use apt commands below. Both of which will automatically install back the pre-installed Snap package.