today's howtos
-
Absolute Path vs Relative Path in Linux
When handling files and directories on Linux, you must know how to work with paths for quick navigation and access to files. A path defines the route to access a given folder or file. Linux’s directory structure resembles the roots of a tree, where everything starts from the root down to the branches until you reach the target file or folder.
Today’s guide focuses on understanding paths on Linux. We will dig in on absolute and relative paths in Linux to understand their differences and how to use each when locating the path to a file or folder.
-
GNU Linux howto – merge concat all mp4 videos in the current directory into one mp4 film movie
-
10 Ways to Generate Secure Passwords on Linux
It's more crucial than ever to use strong passwords for your online accounts. Without a secure password, it's easy for others to crack it. It's great if you can come up with a good password on your own, but if you are out of ideas or feel like your own aren't secure enough, you can get your computer to spit one out for you.
Here are 10 ways you can generate brand-new, secure passwords you can trust on Linux.
-
Export Variables in Bash
The Bash variables are quite different from other programming language variables. The variables in bash do not require declaration, simply use the variable name to specify the data of the variable. The user-defined variables in the bash shell are considered the local variables. It implies that the variables of the shell are not passed down to the shell’s child processes. The variables must be exported by the user before they can be utilized by child processes. The “Export” command of bash is used to export the given variables to an environment where all child processes are running inside the shell. The export command is also referred to as the environment variable.
Environmental variables can be exported to child shells by being labeled with the export command. The export command enables us to notify the active session of any modifications made to the exported variable. The export command takes two arguments where the first argument is the different flags of the export command and the second argument is the variable name which is to be set for exporting in the subshell.
-
Grep for Multiple Patterns or Strings
The users of the Linux operating system can use grep to investigate the various patterns or strings in a file. The grep method of multiple strings or patterns can be used if the operating system contains files with multiple strings and the user wants to target or reach the specified two or more strings from the file. The strings and real path of the relevant file are typically included in the grep command. The pipe symbol can be used to divide them. Before the pipe “|”, we can add a backslash to create the regular expressions. To ignore the cases while doing search operations, the users can use the “-i” option when launching the grep program.