Need a tool to quickly cut and trim lossless video or audio files on Linux? Check out LosslessCut. It’s an electron-based video/audio trimming tool that can handle as much lossless video footage or audio files as you can throw at it. Here’s how to install LosslessCut on Linux.
Note: LosslessCut also runs on Mac and Windows. For more information on those versions of the application, click on this link here.
Install LosslessCut stable
LosslessCut is not a traditional program, and the developer has released no DEB or RPM packages, or even an AppImage for users to use. Since there are no Linux packages to download, we need to work with the generic binary file on the project’s GitHub page to run the app.
To get your hands on the latest Linux binary release for LosslessCut, open up a terminal window by pressing Ctrl + Alt + T or Ctrl + Shift + T on the keyboard. Then, use the wget download command to grab the release archive directly from the internet.
Note: LosslessCut does not support 32-bit. If you require 32-bit, consider trying to build the program from source instead.
After the wget command finishes the process of downloading the LosslessCut Linux binary archive, you’ll need to install the unzip tool to your computer so that you can extract the contents of the file. To install unzip, follow the command-line instructions below that correspond with the operating system you use.
On Ubuntu, Unzip can quickly be installed with the Apt command.
sudo apt install unzip
Those on Debian Linux can easily set up Unzip with the Apt-get command.
sudo apt-get install unzip
Arch Linux users can get their hands on the Unzip tool with the Pacman command.
sudo pacman -S unzip
Using Fedora Linux? Install the Unzip application with the Dnf command.
sudo dnf install unzip
On OpenSUSE Linux, the Unzip app is installable with the Zypper command.
sudo zypper install unzip
With the Unzip application set up on your Linux PC, the LosslessCut archive file can be fully extracted with the commands below.
First, move into the “Downloads” directory using the CD command.
Extract the Zip archive with unzip.
Set up the LosslessCut binary
LosslessCut can run directly from the folder extracted with the Unzip tool. That said, running the program in this way is incredibly inconvenient, and the last thing anyone would want to do before editing some video clips. So, in this section, we will go over how to set up LosslessCut on your Linux PC, complete with a desktop shortcut.
To start, the LosslessCut folder in “Downloads” must be put in the “opt” directory. To do this, start by moving your terminal session to the root user using sudo -s.
Note: do not use su! The sudo -s command will keep you in “Downloads,” and is better suited for this operation.
Now that the terminal window has access to root, use the mv command and place the “LosslessCut” directory in “opt.”
mv LosslessCut-linux-x64/ /opt/LosslessCut/
With the file in place, use the touch command to create a new shortcut file for LosslessCut in “/usr/share/applications/.”
Using the wget downloading tool, grab the following PNG file to use as the icon for your desktop shortcut.
wget https://www.pngrepo.com/download/51032/video-editing.png -O icon.png
Place the newly downloaded “icon.png” file into the “/opt/resources/” directory using the mv command.
mv icon.png /opt/LosslessCut/resources/
Open up the “losslesscut.desktop” file in the Nano text editor with the command below.
nano -w /usr/share/applications/losslesscut.desktop
Paste the following code into the Nano text editor. To paste, press Ctrl + Shift + V.
Comment=LosslessCut video editor.
After pasting the code into the Nano text editor, save the changes by pressing the Ctrl + O keyboard combination. Then, close the Nano text editor by pressing Ctrl + X. Once out of Nano, use the chmod command to set the permissions of the new desktop shortcut file.
chmod +x /usr/share/applications/losslesscut.desktop
Now that the new LosslessCut desktop shortcut file’s permissions have been updated and it is executable, you’ll be able to run the app by clicking on it in the “Multimedia” section.
The source code for LosslessCut is available on GitHub if you’d prefer to download it and build the app yourself, rather than using the Linux generic binary covered in this article. For more information on how to build LosslessCut from source on Linux, click here.