The Linux Rain Linux General/Gaming News, Reviews and Tutorials

Articles found under tag: bash

Finding unmatched braces (brackets)

By

Recently I was checking for unmatched braces in a big text file with nearly half a million lines (300+ MB). Was there a closing brace for every opening brace? The text file was called 'beetle' and was actually a tab-separated table with each line divided into 77 fields. What I wanted to do was find…

Read Article

How to use flags in AWK

By

Flags in AWK are variables which are set to either true or false. They're handy for defining ranges over which AWK can act, as shown below. The AWK used here is GNU AWK 4.1.1 (gawk 4). Sometimes flags aren't needed I'll demonstrate with a simple text file called demo, which has 6 lines with 3…

Read Article

Proofreading for illusions with grep and AWK

By

Lexical illusions are very hard to find when proofreading. The most common lexical illusion is a duplicated word, as in this well-known example: A lexical illusion: many people are not aware that the the brain will automatically ignore a second instance of the word 'the' when it starts a new line. …

Read Article

Transposing rows and columns: 3 methods

By

Swapping the rows and columns in a table on the command line would seem to be a fairly easy thing to do. For example, with this tab-separated table (called 'tabbed') as input: get this tab-separated table ('swapped') as output: Datamash Transposing rows and columns is indeed easy if you have the…

Read Article

I think I like backreferences (sometimes)

By

Backreferences are part of the complicated and sometimes confusing world of regular expressions. The basic idea is this: you can substitute any part of a regular expression with a backslash followed by a number, so long as you surround the part to be substituted with round brackets. The command…

Read Article

Keeping emails as text files: 2 scripts

By

Most people store and organise their personal emails as individual files (messages) in folders. Those folders might be on a webmail company's servers, or in a mail client program on the user's personal computer. In both cases the emails are probably in a special email format. I'm horribly…

Read Article

Scripting a fancy chooser for recently used files

By

I recently scripted a GUI dialog that lists my 10 most recently modified files in reverse chronological order and allows me to choose more than 1 file for opening. The dialog is launched with a keyboard shortcut and is shown here with 2 files selected: The script is in copy-and-paste form at the…

Read Article

Gnumeric: a filter-and-export script

By

My wife likes to organise and store information in Gnumeric spreadsheets. Every now and then she needs to filter her data and save the result to a new spreadsheet. Gnumeric doesn't have a simple way to do that. It has a complicated way to do it ('Advanced Filter'), but nothing so straightforward as…

Read Article

How to insert code snippets on the command line without executing them

By

You can store a code snippet in a shell alias or a function, but when you type the alias or function name in a BASH shell and press 'Enter', the shell executes (or tries to execute) the snippet. That's no good if the snippet is incomplete or needs editing. A simple workaround is to paste the…

Read Article

How to read a file N lines at a time in BASH: 3 methods

By

The file I'll be using for this demonstration is called demo and looks like this: demo is plain text with 2 tab-separated columns. The first column is sorted alphabetically, but the second column isn't sorted. What I want to find out is how many different letters are in the second column for each…

Read Article

News Elsewhere

Linuxtoday.com

Intel Core i7 6800K Benchmarks On Ubuntu + Linux 4.8

Phoronix: While the Core i7 6800K has been available for a few months now, there hadn't been any review on it since Intel hadn't sent out any Broadwell-E samples for Linux testing this time around.

Improving Fuzzing Tools for More Efficient Kernel Testing

Linux.com: Bamvor Jian Zhang of Huawei will share some ways to improve the trinity fuzzing tool for more efficient unit tests in his upcoming talk at LinuxCon Europe.

The Ultimate Guide to Increase Transfer Speeds of Nginx Websites Using 'Gzip' Module

tecmint: In this article we will discuss a method to increase transfer speeds by reducing the file sizes through compression.

LXQt 0.11.0 Desktop Environment Arrives After Almost One Year of Development

LXQt 0.11.0 is finally here as a worthy upgrade to LXQt 0.10.0, which was announced back in November 2015 and currently used in several GNU/Linux distributions

Super Mario Clone SuperTux 0.5.0 Is Out with In-Game Level Editor, Improvements

The biggest new feature of the SuperTux 0.5.0 update is a new in-game level editor that lets you create your own levels or modify exiting ones to your liking.

Linux 4.8 rc8

Linus Torvalds: So as already mentioned last week (and hinted at as a possibility), here's rc8.

PostgreSQL 9.6 Preparing To Release With Its Parallel Queries Support

Phoronix: PostgreSQL 9.6 is being prepared for release on 29 September as the database system's latest major update.

DDoS Attacks Heading Toward 1-Terabit Record

eWEEK: Although a 665G-bps attack is considered an outlier today, there will likely come a day when it is not looked at that way.

How do you get programmers to join your project?

This month The Queue answers the question "How can I get programmers to join our project?"

GamingOnLinux.com Latest Articles

Yooka-Laylee has another trailer, featuring Shovel Knight

Tags:Coming Soon,Platformer,Teaser,VideoThat's right, Shovel Knight has somehow found his way into Yooka-Laylee [Official Site] and here's a trailer…

hackmud, a cyberpunk themed text-based hacking simulator is now out with Linux support

Tags:Simulation,Indie Gamehackmud, or "h a c k m u d" [Official Site, Itch, Steam] as it likes to be called is now out with Linux support from day-1.…

Future Unfolding is a fantastic looking action and adventure game with rather unique visuals

Tags:Action,Adventure,Coming Soon,Greenlight,Indie Game,Puzzle,SteamFuture Unfolding [Official Site] from Spaces of Play looks rather unique in style…

The Long Dark gets a massive update, which fixes a critical Linux audio bug

Tags:Survival,Steam,Sandbox,GOG,Early Access,Unity3DThe Long Dark [Official Site, Steam, GOG] is the rather beautiful survival game currently in…

On Wednesday the 28th of September Feral Interactive will livestream Warhammer 40,000: Dawn of War II on Linux

Tags:Livestream,Feral InteractiveIf you're excited about the release of Warhammer 40,000: Dawn of War II for Linux you may want to tune in to Feral…

GOG are running a back to school sale and GOG Connect has returned with new games

Tags:GOG,Game SaleGOG [Official Site] has a bunch of titles on sale right now and they have also announced the return of GOG Connect which allows you…

‘The Hive’, a story driven fantasy game that plays like an RTS leaves Early Access, some thoughts

Tags:Strategy,Steam,Review,Indie GameI was really excited when I remembered The Hive, and now it’s out of Early Access I have given it some…

Worms W.M.D should have multiplatform online play by the end of October, including between GOG and Steam

Tags:Action,GOG,Steam,Strategy Worms W.M.D [Official Site] is set to get an update around the end of October that will include multiplatform…

Promising top-down shooter ‘Redie’, inspired by Hotline Miami, needs support on Kickstarter, demo available

Tags:Action,Coming Soon,Crowdfunding,Indie GameRedie sincerely took me by surprise when I was researching another game. It got my attention from the…

The third beta of FREE FPS ‘Ravenfield’ is out, the game keeps getting better

Tags:Beta,FPS,Free Game,Itch.io 'Ravenfield' is a small but excellent FPS inspired by Battlefield (but without Multiplayer), which I previously…

Heroine's Quest: The Herald of Ragnarok is coming to Linux, developer looking for testers

Tags:Adventure,Coming Soon,Itch.io,RPG,SteamHeroine's Quest: The Herald of Ragnarok [Official Site] a hybrid RPG/Adventure game will come to Linux.…

For a few more days, you can get both 'Frederic' rhythm games for a massive 90% discount, demos available

Tags:Music,Indie Game,Game Sale,Demo,CasualThere is a huge 90% discount for a double package featuring both 'Frederic' rhythm games until September…

'SOMA' from Frictional Games sales figures released, Linux accounted for around 1.1% of sales

Tags:EditorialFrictional Games, the developers of 'SOMA' [Official Site] have released their sales figures. The game sold about 450,000 copies of…

Join us for another weekly livestream tonight at 19:45 UTC

Tags:LivestreamTonight is the night we face hell, terrorists and rocket powered cars together. That's right it's Friday, it's No Pants Friday and…

Warhammer 40,000: Dawn of War II, Chaos Rising and Retribution announced for Linux this month!

Tags:Strategy,Steam,Feral Interactive,Coming SoonDo not adjust your monitors, you read that correctly. Warhammer 40,000: Dawn of War II, Chaos Rising…