Updated: 28 January 2026
See https://askubuntu.com/questions/774490/what-is-an-appimage-how-do-i-install-it
Make an Appimage executable
chmod a+x exampleName.AppImage
Run an Appimage
./exampleName.AppImage
Freelance software engineer United Kingdom
Updated: 28 January 2026
See https://askubuntu.com/questions/774490/what-is-an-appimage-how-do-i-install-it
Make an Appimage executable
chmod a+x exampleName.AppImage
Run an Appimage
./exampleName.AppImage
Updated: 30 January 2026
Taken from here
nix-collect-garbage.flake.nix and flake.lock at the root.A flake output can be used to:
See here for more details.
https://github.com/nix-community/home-manager
Run a program without entering a nix shell
nix-shell -p cowsay --run "cowsay Nix"
Enter a nix shell making 2 new packages available
nix-shell --packages cowsay lolcat
Enter a nix shell including Java Development Kit version 17
nix-shell -p jdk17
Enter a nix shell which includes PHP 8.4
nix --extra-experimental-features "nix-command flakes" shell nixpkgs#php84
Enter a nix shell which includes PHP 5.6
nix --extra-experimental-features "nix-command flakes" shell nixpkgs#php56
Updated: 18 April 2025
Remove snap, without saving a snapshot of its data
snap remove --purge lxd
Show detailed information about snaps
snap info lxd
Search for a snap package
snap find lxd
List installed snaps
snap list
List installed snaps
ls -l /var/lib/snapd/snaps
Show symbolic links to snap applications
ls -l /snap/bin
Delete snapd cache
sudo rm -rf /var/lib/snapd/cache/*
Updated: 06 April 2025
Advanced Packaging Tool.
From man apt-get
update is used to resynchronize the package index files from their sources. The indexes of available packages are fetched from the location(s) specified in /etc/apt/sources.list. For example, when using a Debian archive, this command retrieves and scans the Packages.gz files, so that information about new and updated packages is available. An update should always be performed before an upgrade or dist-upgrade. Please be aware that the overall progress meter will be incorrect as the size of the package files cannot be known in advance.
sudo apt-get update
From man apt-get
upgrade is used to install the newest versions of all packages currently installed on the system from the sources enumerated in /etc/apt/sources.list. Packages currently installed with new versions available are retrieved and upgraded; under no circumstances are currently installed packages removed, or packages not already installed retrieved and installed. New versions of currently installed packages that cannot be upgraded without changing the install status of another package will be left at their current version. An update must be performed first so that apt-get knows that new versions of packages are available.
sudo apt-get upgrade
Install a single package:
sudo apt install unattended-upgrades
List installed packages
apt list --installed
Upgrade a single package
apt-get install --only-upgrade <packagename>
Remove a package
sudo apt --purge remove package-name
sudo apt --purge autoremove
Show currently installed and candidate versions of a package
apt-cache policy doxygen
Updated: 12 December 2025
See https://canonical.com/lxd
Support https://discuss.linuxcontainers.org/
List instances
lxc ls
List instances in longer json format
lxc list --format=json | jq
Start instance win11 and immediately attach to the console
lxc start win11 --console=vga
Prevent a container from automatically starting whenever the LXD host starts
lxc config set the_container boot.autostart false
Stop the instance called win11, with force
lxc stop --force win11
Delete container win11
lxc delete win11
Enter a container as user sammy
lxc exec the_container -- su sammy
Start a container
lxc launch ubuntu:24.04
Start a virtual machine
lxc launch ubuntu:24.04 --vm
Start a NixOS virtual machine (credit)
lxc launch images:nixos/25.05 --vm nix
Create a snapshot of a container
lxc snapshot container_name snapshot_name
Show a list of available snapshots
lxc info container_name
Select and restore a snapshot
lxc restore container_name snapshot_name
Delete a snapshot
lxc delete win11d/the_first_shot
Remove a device e.g. iso CD
lxc config device remove container_name device_name
List devices associated with an instance
lxc config device list container_name
Hit host IP address from inside a LXC container, assuming container uses lxdbr0 attached to same network as host
# Get IP of host.
curl ifconfig.me
# From container curl for http service running on host port 80.
# IPv6 version address in this case.
curl -6 http://[2401:d800:3f1:ba7b:f02c:a795:f128:864]
Updated: 26 January 2026
Remove user sammy from the docker group
deluser sammy docker
Change a user password
sudo passwd the_user_name
List all users on a Linux system
cat /etc/passwd
Updated: 31 August 2025
Print distribution specific information
lsb_release -d
Package manager for Debian
Get architecture (e.g. AMD or ARM) of machine this command is run on i.e. the architecture of packages installed by dpkg.
dpkg --print-architecture
Updated: 06 July 2024
systemctl suspend
systemctl hibernate
sudo poweroff
Stop running processes then reboot immediately:
sudo shutdown now -r
Updated: 07 September 2024
Super + Shift + PageUp |
Move active window to a workspace left of the current workspace |
Super + Shift + PageDown |
Move active window to a workspace right of the current workspace |
Ctrl + Alt + T |
Open new terminal |
Updated: 04 February 2021
On Linux I like to make use of the select and paste feature i.e. selecting text copies it and the middle mouse button pastes it. When a laptop touchpad has no buttons a middle mouse click can be simulated with a three-finger tap, but this is awkward.
Here is my workaround (for keyboards with a numeric keypad only):
Furthermore, in a terminal and some other applications SHIFT + INSERT will paste text which has been previously selected.
I am using Ubuntu 20.04.1 and GNOME 3.36.8