BASH Scripting Guide - PART - 3

Bash or shell won’t be much popular and powerful if they didn’t have some tools and utilities baked in. But even further they are supported natively in Bash, which just makes every task and challenge quite hassle-free to deal with. In this part of the series, I’ll try to cover an overview of some quite powerful and robust tools and utilities in Bash(shell in general) and also some of the advanced topics like dictionaries and positional parameters. Enough talk let’s dive in.

[]

Learning BASH by making a Number game

Introduction

OK! Learning BASH can be quite confusing without a proper goal in hand. So this will be a pretty good idea to start learning BASH and have a ton of fun. In this little time, we’ll make a Number game which I have designed myself last year in C++, which took about 3 months due to lazy research and wasting time. But I was surprised that I made this game within two hours in BASH. You can refer to the game instructions in this repository at Github.

[]

BASH Scripting Guide - PART - 2

Introduction

In this part, topics such as switch cases, mathematical expression, arrays, and strings. This won’t be an in-depth guide to understand each and every concept, but to make users aware of the things and features in Bash. This also would not be an absolute basic guide, I expect to have some basic programming knowledge such as binary systems, logical and mathematical concepts. Don’t worry, you won’t be bombarded with commands, I’ll just explain with easy examples to get started.

[]

Vim: Terminal Integration

Vim and Terminal!?

Vim was made to work with the command line. Many beginners do not understand what are the true capabilities of Vim, myself included:) Vim can run terminal commands without leaving the text editor, open an instance of a terminal, work with shell environments, and other things depending on the use case.

Running Terminal/ shell commands from within Vim

You can run the commands from inside of Vim by just using :! before the command, this means you have to be in command mode. Just after being in command mode, the ! or bang operator will execute the command typed after it from the terminal(Linux/ macOS) or your default shell(Windows -> CMD/Powershell).

[]

Vim: Enhancing Movement Speed

![]({{ page.image | relative_url }})

Introduction

OK! Vim and movement are like bread and butter or failed brakes. To become a proficient Vim user, you need to move in Vim very effectively. You don’t have to think about doing certain things, your fingertips should automatically move without wasting time thinking about it. I am sure, it takes time and effort but OH! it is so rewarding in the end.

Why H J K L?

First things first, unmap arrow keys and make a habit of using h,j,k, and l. Yes, this would not make any sense in the initial stage but that will make no sense for not using it later. The thing with H J K L is that they are quite flexible to work with and if you use it with numbers you would navigate much faster than arrow keys. Such as 10j will move you 10 lines down at a time in normal mode. These keys are used with many of the other key shortcuts and commands which just make it most important to begin learning to move around in Vim with H J K L.

[]

BASH Scripting Guide - PART - 1

Introduction

If you are new to BASH and Linux, don’t you worry the community is the driving force here. If someone’s stuck somewhere, the platforms, forums, and blogs are ready to help anyone there. BASH is a short term of Bourne-Again Shell, it is a shell interface that has much more capabilities and functions than the simple Bourne shell(sh). It has some quite remarkable features and it is even capable of calling itself a programming language in some sense.

[]

What is BASH?

Introduction

BASH or Bourne Again Shell is an interface(program) between the user and the Operating System. BASH is just an application just like others, but not an ordinary one. It is quite powerful when used to its potential. It is used in various aspects of computing. No, it’s not only for server admins, but it specializes in that field though. We’ll see how we can use Bash to perform several tasks quite powerfully. Not just automation, you’ll be surprised what Bash is capable of.

[]

Vim: Keymapping Guide

Introduction

Keymapping or Key binding is a process in which a user or a system can assign certain keys or commands to perform a particular task or commands. This can be quite useful in Vim as well as in other text editors to avoid some repetitive tasks and save time. In Vim this can be a great power to have for programmers as it can be really very flexible to set up for any programming language and it’s environment.

[]

Setting up Vim for BASH Scripting

Vim and BASH?

Bash Scripting is a powerful skill to have as a programmer because we find Linux almost everywhere and to get through it you must have a command over its interface which is generally the BASH shell. Vim is a great option for doing this, or probably the best out there! Because Vim is pre-installed in almost every Linux distribution. This is not an in-depth setup for BASH on Vim, it is a simple editorial on starting up BASH scripting on the Vim editor. So without wasting time on “Vim features” let’s dive in with the setup for BASH in Vim.

[]

Setting up Vim for Python

Introduction

Vim is quite a powerful text editor which can add performance to the already fast typed language Python. Vim can be highly customizable and efficient to use as it has the power of adding custom plugins and plugins managers, key mappings, and the most critical weapon of vim - Access to the terminal straight away. This is not a full-featured guide of using vim for python, it’s just a quick setup for using python on vim blazingly fast!!

[]