How to test if a C program on Linux is running from a TTY or not.

This simple C program will test whether it is running from a TTY or not. This is a simple test, but it could be quite useful. #include <stdio.h> #include <poll.h> #include <unistd.h>   int main(int argc, char* argv[]){   struct pollfd fds[1] = {{.fd = STDIN_FILENO, .events = POLLIN}};   if (!poll(fds, sizeof(fds) / sizeof(struct … Read more

Very interesting Bash shell script for creating a Webm clip from a movie.

This is a very useful Bash shell script, this will create a Webm clip from a movie. This shows how to get parameters in a Bash script easily. #!/bin/bash   while [[ "$#" -gt 0 ]]; do case $1 in -f|–filename) filename="$2"; shift ;; -t|–timestamp) timestamp="$2"; shift ;; -o|–outfile) outfile="$2"; shift ;; *) echo "Unknown … Read more

How to encode a movie clip with FFmpeg and have the encoding start right away.

Encoding a movie clip with FFmpeg is very simple, but getting the encoding to start right away is the hard part. Sometimes it will take many seconds to start, but this is due to the slow searching through the file looking for the right section. Putting the “-ss 01:58:11” parameter before the “-i” parameter is … Read more

Build Stalker information and sketches.

I have found a very nice archive, this is a lot of build Stalker Call of Pripyat information and sketches. There is a lot of spreadsheets with artifact statistics as well. This would be very interesting to any Stalker fan. Download it here: https://mega.nz/file/ppxESI6T#sJaSjCzDyuxSO6pZU18Jbi3Y4_6O63zV-MLlYFsz3As. There are also a few photos of the Jupiter Factory from … Read more

How to get the best quality when creating a webm with FFmpeg.

Rip a Youtube video to a good quality Webm with FFmpeg This very useful command will get a Youtube video and rip a certain timeframe from the video to a good quality WebM file. Create a Webm with FFmpeg. ┌──[[email protected]]─[~/Videos] └──╼ ╼ $ ffmpeg -ss 00:00:55 -to 00:01:05 -i `yt-dlp -g -f bestvideo GbPK2VCarvU` -threads … Read more

Some very old but nice UNIX bitmap wallpapers.

This old archive is a collection of very old UNIX bitmap wallpapers. https://securitronlinux.com/maps/bitmaps.7z. These should be quite useful if you wish to set up a retro desktop and wish to have a retro tiling wallpaper as well. Also, I have a nice collection of all Windows `98 wallpapers. https://securitronlinux.com/linux/maps/Windows98.rar. That should also be very useful … Read more

How to print out all available terminal colors. And other useful Linux tricks.

How to best view all available terminal colours This one-liner will print out all available terminal colours for your chosen Linux terminal application. This is very useful for creating a colourful bash prompt and the user wishes to know which colour codes will work and look good in the terminal. for x in {0..8}; do … Read more

Gorgeous Linux themes for the modern desktop.

Some very nice themes for your Linux desktop in 2021 Some very nice themes for your Linux desktop in 2021Gnome Shell themesWallpapersIcon themes Gnome Shell themes MetalX Gnome Shell theme for Linux. https://www.deviantart.com/art/Metal-X-theme-v-2-1-for-Gnome-3-16-577064989. Android Flat Gnome Shell theme. A nice flat grey theme for your Gnome desktop. https://www.deviantart.com/art/Android-Flat-3-18-565622252. Ambiance Gnome. https://www.deviantart.com/art/Ambiance-Gnome-3-14-1-8-GNOME-Shell-theme-476996106. An Ubuntu inspired theme … Read more

How to simulate color blindness on Ubuntu or Linux Mint easily.

Simulating colour blindness is very useful for a graphics designer or web developer, this allows the designer to test if the graphics are visible properly when using various colours on buttons and hyperlinks. There is a very useful application that can help with this. This is called Color Oracle. This is a Java app and … Read more

Some very interesting Linux desktop themes for GTK.

Nice themes for your Linux desktop Some very nice themes for your Linux desktop in 2021Gnome Shell themesWallpapersIcon themesNice themes for your Linux desktopWindow themesDesktop wallpapers Window themes Google Chrome Metacity theme for MATE and Gnome Shell. This is a nice Google Chrome inspired theme for MATE and Gnome Shell. This is a very good … Read more

How to save your place in a movie when exiting MPV.

Saving your place in a movie when exiting MPV is very easy, this would be very useful when watching a long film and you need to exit the player and watch some more later. Add this to the ~/.config/mpv/mpv.conf file. save-position-on-quitsave-position-on-quit This will allow the player to resume playback when you restart playing a movie … Read more

How to block scripts in Firefox with uBlock origin.

Blocking scripts in uBlock origin is very easy, if you know the path to an annoying script, it may be easily blocked. Open the dashboard in uBlock origin and use the code below to block the script. ! 2021-05-25 https://boards.4channel.org ||bid.glass/lib/bg.js$script,domain=boards.4channel.org! 2021-05-25 https://boards.4channel.org ||bid.glass/lib/bg.js$script,domain=boards.4channel.org This is another example, blocking the end screen and annotations in … Read more