Overview We’ll look at some ways to create a complete Linux path by combining two paths into one. We’ll first look at some basic techniques for accomplishing this. Then, we'll talk about a generic approach that handles some of the special cases that appear when combining paths. Concatenating Strings to Build a Path We'll start by looking at an example where we want to concatenated strings to create a complete path. $ my_home_dir="/home/shubh/baeldung/" Here we assume that the current directory is where we want to clone the Git repo from. We then create a new folder called my_home_dir inside the ... Read More
Overview We’ll look at how the operating systems behave when we delete, move or replace files that have open handles. We’ll first briefly talk about files and inodes. After that, we’ll look at the different scenarios and see which one occurs in each case. Understanding Files and Inodes Files stored on a Linux file system use inode numbers to keep track of their contents. We usually list the contents of a directory by listing its file names (links) and then their corresponding inode numbers (hard links). We can use stat on a file and see which inode it refers to ... Read More
Overview In this article, we will discuss how to solve the unary operator expected error in Linux. This is one of the most common errors that you may encounter while working with Linux. In this post, we will see how to fix it and what are the possible causes for this error. What Is Unary Operator Expected? The unary operator expects is a type of syntax error that occurs when an expression has only one operand. For example − int x 5; //error - unary operator expected The above code snippet shows an error because there is no binary operation ... Read More
Overview The Linux terminal is an important tool for any user of the operating system, and it's often used to perform various tasks such as viewing log files or running commands. However, sometimes you may need to clear a screen on your computer so that you can see more than one thing at once. In this article we'll look at how to clear a screen in Linux. It’ll be helpful if we clear the command prompt window so that we can see more clearly what we're doing. We’ll discuss the different ways to accomplish this. Using the clear Command You ... Read More
Overview ImageMagick is an open source software suite for image manipulation. We can install it on our system using apt−get and then run commands through its command line interface (CLI). We’ll take a quick peek at some of the most popular methods for manipulating images with ImageMagick. Installation Let’s start by downloading ImageMagick, which we can install using our package manager (e.g., apt). We can also download the binary directly or compile it from the sources. After installing the software, let’s check whether we've successfully installed it by looking at its current status. $ magick -version Version: ImageMagick 7.0.8-13 Q16 ... Read More
Overview You may sometimes want to run several commands sequentially in Linux. To accomplish this, you can use command chaining. For example, if you wanted to download a compressed archive, decompress it, and then remove the resulting archive from disk, you could type these three commands together. Here, we’ll look at some methods for serializing commands using Bash in Linux. Even if they're already running. Inline Command Chaining Bash has great flexibility and powerful features for the end−users. We can create long sequences of instructions to perform any number of tasks. ... Chained operations ... Read More
Maintaining the value of a particular item at every instance of time is a very crucial process if the prices of the item change very frequently. If we want to note the value of an item in particular intervals, then we need to create a list that contains the time with hours/minutes/seconds increment. For example, such a list is quite useful in case of stock prices because they change rapidly. Although we can’t note every value, we can note the value for all particular intervals, like for every 15 minutes, to analyse its change of price. How to Add Time ... Read More
An email address of a person, in most cases, is generally a combination of the first and last name, ending with the host details such as @gmail.com, @yahoo.com, etc. Suppose we have an Excel sheet with two columns containing the first and last names of employees, then we can easily append their email addresses in a third column, by combining the data values of the first two columns. Adding Email Address to a List of Names We can follow a simple process to add email addresses to a list of names. Basically, this process contains two parts, the first step ... Read More
Let's suppose you need to add a particular text string in all the cells of an Excel sheet at the beginning or end of the existing data. It can be a tedious process if you decide to perform this such a task manually. In this tutorial, we will show you a simple method by which you can do it using a formula in Excel. We can add text in beginning or end using the same formula but the process is sequence of the work is different. Let us see the simple process to add text in bigging or end of ... Read More
Suppose you have an Excel sheet with a column of data and you need to add a string of text at a specific position in all the column data. In such cases, you don't have to type the entire data all over again to update the given column data. In this tutorial, we will demonstrate in a few simple steps how you can add the new data in between an existing set of data. Add Text in the Middle of Selected Cells in Excel Suppose we have an Excel sheet with a list of data that starts with the letter ... Read More
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP