This tutorial covers programming language features in

  • DOS
  • Bash
  • Shell
  • zsh

Dos has abbreviated as disk-based operation systems for windows OS.

It has different flavors MS-DOS IBM PC DOS

The current version is DOS 9 in Windows 12 Operating System

Linux and UNIX have different scripts like bash and Shell scripts

What is sh in the terminal?

sh is a shell, command language used to execute code from a script file. It takes input from the keyboard and executes script files and does output.

How do I run a .sh file in Terminal?

To execute the sh files, Please follow the below steps

  • Open terminal
  • make sure that the sh file has to execute permission to execute
  • Run script file using ./scriptfile.sh

How can I get the current date and time in the terminal

To get the current date and time in the terminal, please follow the below steps

  • Open terminal
  • Run date command, which results in the current date and time of the day.
date

What is terminal?

Terminal also called command line in Most of the operating Systems.Terminal used to execute script files in OS.

  • Unix: Called as Shell command line
  • Windows: Command prompt
  • MacOS: Terminal Window

Latest Articles

Bash - Tutorials

Bash Shell scripting tutorials and programming examples

Posted January 1, 0001 by  ‐ 1 min read

Bash - Loop File

How to loop contents of a file in Bash Shell scripting tutorials and programming examples

Posted August 20, 2023 by  ‐ 1 min read

Bash - Variables

In this tutorial, Learn variable declaration, types of global and local readonly variables accessing the variables with syntax, and examples in bash shell script programming

Posted August 20, 2023 by  ‐ 3 min read

Bash - Comments

In this tutorial, Learned to insert single and multi-line comments syntax and examples in shell and bash script files

Posted August 20, 2023 by  ‐ 2 min read

Bash - Arrays

In this tutorial, How to create indexed and associated arrays add, remove get iterate loop first and last elements of array s syntax and examples and array cheat sheet shell examples

Posted August 20, 2023 by  ‐ 4 min read

Bash - Append String

Bash scripting tutorial on programming examples for concatenating string variables using simple append and shorthand arithmetic operator

Posted August 20, 2023 by  ‐ 2 min read

Bash - Check Directory

Bash scripting tutorials on programming examples for checking directory exists or not multiple directories check, files exist, the directory does not exist, create a directory ternary and if statements, directory write and executable permissions

Posted August 20, 2023 by  ‐ 2 min read

Bash - Numbers Comparison

Bash scripting tutorials on programming examples for if two numbers are equal or not

Posted August 20, 2023 by  ‐ 1 min read

Bash - File Name

Bash or shell script example for an extract file name for complete path, filename only without extension and extract extension

Posted August 20, 2023 by  ‐ 2 min read

Bash - bashrc

Bash or shell script .bashrc reload and location example for Split string into multiple strings using awk and ifs examples

Posted August 20, 2023 by  ‐ 2 min read

Bash - Split String

Bash or shell script example for Split string into multiple strings using awk and ifs examples

Posted August 20, 2023 by  ‐ 1 min read

Bash - String length

Bash or shell script example for Finding the length of a string with examples

Posted August 20, 2023 by  ‐ 1 min read

Bash - Ternary Operator

Bash or shell script example for Ternary Operator expression with examples

Posted August 20, 2023 by  ‐ 1 min read

Bash - Lower Case

In this tutorial, learn multiple ways to convert a string to lowercase in bash and shell programming.

Posted August 20, 2023 by  ‐ 2 min read

Bash - Substring

Bash scripting tutorials on programming examples for checking directory exists or not multiple directories check, files exist, the directory does not exist, create a directory ternary and if statements, directory write and executable permissions

Posted August 20, 2023 by  ‐ 1 min read

Bash - Upper Case

In this tutorial, learn multiple ways to convert a string to upper case in bash and shell programming.

Posted August 20, 2023 by  ‐ 2 min read

Bash - variable set

In this tutorial Check variable is set or unset in bash and shell script files with code examples

Posted August 20, 2023 by  ‐ 3 min read

Bash - Iterate Nos

In this tutorial Check variable is set or unset empty or non-empty with an empty string or not in bash and shell script files

Posted August 20, 2023 by  ‐ 1 min read

DOS

MSDOS basics and programming language tutorials

Posted January 1, 0001 by  ‐ 2 min read

DoS - Logical

How to use logical operators and or in DOs batch programming example.

Posted January 1, 0001 by  ‐ 1 min read

DoS - Pause

How to do pause with enter key Batch file DOs batch programming example.

Posted January 1, 0001 by  ‐ 1 min read

DoS - Comments

Step-by-step tutorial on How to add a comment in a cmd dos batch programming in dos batch programming.

Posted January 1, 0001 by  ‐ 1 min read

DoS - Variables

Step-by-step tutorial on how to define local global variables environment variables and reference prompt to read value and store numeric values with examples setx,set command in dos batch programming.

Posted January 1, 0001 by  ‐ 3 min read

DoS - IF block

Learn if blocks if else statements and nested if else examples in dos batch programming. Check variable is defined or not

Posted January 1, 0001 by  ‐ 2 min read

DoS - For Loop

Iteration in DOS using for loop An example to iterate files in a directory in dos batch programming.

Posted January 1, 0001 by  ‐ 1 min read

DoS - Create empty file

How to create an empty file with the command line in windows for example.

Posted January 1, 0001 by  ‐ 1 min read

DoS - New Line

How to echo new line break or blank line and write to file in DOS programming.

Posted January 1, 0001 by  ‐ 1 min read

DoS - Increment Variable

How to increment variable or counter in .bat files in For loop incremental variable in DOS programming.

Posted January 1, 0001 by  ‐ 1 min read

DoS - Run Multiple Files

How to run multiple .bat files in sequential and parallel order in DOS programming.

Posted January 1, 0001 by  ‐ 2 min read

DoS - Current Directory

How to use the current directory in batch code. append the filename to the current directory Run another bat or exec file from the current working directory.

Posted January 1, 0001 by  ‐ 2 min read

DoS - Directory List

How to list directories and subdirectories in a folder command line in windows with example.

Posted January 1, 0001 by  ‐ 2 min read

DoS - Shutdown

How to shutdown restart logoff stop a window machine using the batch program shutdown command in windows to reboot and hibernate forcibly

Posted January 1, 0001 by  ‐ 2 min read

DoS - Tree Command

How to display a tree view of files and folders in Windows And DOS command tree with f and a options

Posted January 1, 0001 by  ‐ 2 min read