<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="https://script.spoken-tutorial.org/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=BASH%2FC2%2FIntroduction-to-BASH-Shell-Scripting%2FKhasi</id>
		<title>BASH/C2/Introduction-to-BASH-Shell-Scripting/Khasi - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=BASH%2FC2%2FIntroduction-to-BASH-Shell-Scripting%2FKhasi"/>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=BASH/C2/Introduction-to-BASH-Shell-Scripting/Khasi&amp;action=history"/>
		<updated>2026-05-14T09:56:46Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.23.17</generator>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=BASH/C2/Introduction-to-BASH-Shell-Scripting/Khasi&amp;diff=36832&amp;oldid=prev</id>
		<title>Meboreen Mary at 11:32, 30 April 2017</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=BASH/C2/Introduction-to-BASH-Shell-Scripting/Khasi&amp;diff=36832&amp;oldid=prev"/>
				<updated>2017-04-30T11:32:09Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;https://script.spoken-tutorial.org/index.php?title=BASH/C2/Introduction-to-BASH-Shell-Scripting/Khasi&amp;amp;diff=36832&amp;amp;oldid=36831&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>Meboreen Mary</name></author>	</entry>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=BASH/C2/Introduction-to-BASH-Shell-Scripting/Khasi&amp;diff=36831&amp;oldid=prev</id>
		<title>Meboreen Mary: Created page with &quot;{| border =1 |'''Time''' |'''Narration'''  |- | 00:01 |Dear friends, welcome to the '''Spoken tutorial''' on '''Introduction to BASH shell scripting'''.   |- |00:08 |In this t...&quot;</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=BASH/C2/Introduction-to-BASH-Shell-Scripting/Khasi&amp;diff=36831&amp;oldid=prev"/>
				<updated>2017-04-30T11:31:06Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;{| border =1 |&amp;#039;&amp;#039;&amp;#039;Time&amp;#039;&amp;#039;&amp;#039; |&amp;#039;&amp;#039;&amp;#039;Narration&amp;#039;&amp;#039;&amp;#039;  |- | 00:01 |Dear friends, welcome to the &amp;#039;&amp;#039;&amp;#039;Spoken tutorial&amp;#039;&amp;#039;&amp;#039; on &amp;#039;&amp;#039;&amp;#039;Introduction to BASH shell scripting&amp;#039;&amp;#039;&amp;#039;.   |- |00:08 |In this t...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{| border =1&lt;br /&gt;
|'''Time'''&lt;br /&gt;
|'''Narration'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:01&lt;br /&gt;
|Dear friends, welcome to the '''Spoken tutorial''' on '''Introduction to BASH shell scripting'''. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|00:08&lt;br /&gt;
|In this tutorial, we will learn: &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:10&lt;br /&gt;
|About different types of '''Shells'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:13&lt;br /&gt;
|To write a '''Bash Shell script''' and&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:16&lt;br /&gt;
|To execute it.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|00:18&lt;br /&gt;
| To follow this tutorial, you should be familiar with '''Linux Operating System'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|00:25&lt;br /&gt;
|If not, then for relevant '''Linux''' tutorials, please visit our website which is as shown.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:32&lt;br /&gt;
| For this tutorial, I am using: &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:35&lt;br /&gt;
| '''Ubuntu Linux 12.04''' OS and &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:39&lt;br /&gt;
|'''GNU Bash''' version '''4.1.10'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:43&lt;br /&gt;
| Please note, '''GNU Bash''' version '''4''' or above is recommended for practice.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|00:50&lt;br /&gt;
| Let us start with an introduction.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|00:53&lt;br /&gt;
|We will see what a '''Bash Shell '''is.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 00:56&lt;br /&gt;
| '''Bash Shell''' is a '''command language interpreter''' that '''executes''' '''commands'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 01:02&lt;br /&gt;
| These '''commands''' are read from the '''standard input''' device. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 01:07&lt;br /&gt;
| The input device can be- &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|01:09&lt;br /&gt;
| your '''keyboard'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|01:11&lt;br /&gt;
| or a simple''' text file'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 01:14&lt;br /&gt;
| Let me show you what is a '''Bash Shell'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 01:16&lt;br /&gt;
| Open the '''terminal''' '''window''' by pressing '''Ctrl+Alt+T''' keys simultaneously on your keyboard .&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|01:24&lt;br /&gt;
|This will open the '''Gnome terminal'''.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|01:27&lt;br /&gt;
|To check which '''type''' of  '''shell''' we are using, type:  '''echo space dollar sign SHELL''' (in capital).&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|01:38&lt;br /&gt;
|Press '''Enter'''.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|01:40&lt;br /&gt;
| You will see the '''output''' printed on the next line as:  '''slash bin slash bash'''.&lt;br /&gt;
  &lt;br /&gt;
|-&lt;br /&gt;
|01:47&lt;br /&gt;
|This indicates that we are using the '''Bash Shell'''.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|01:51&lt;br /&gt;
| Now, let us know different types of  '''Shells '''available.  &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|01:56&lt;br /&gt;
|Let us switch back to our '''slides'''. Bourne Shell-&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|02:00&lt;br /&gt;
|This was original UNIX '''shell''' written by Stephen Bourne.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|02:06&lt;br /&gt;
| It lacked interactivity provided by most modern shells today.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 02:11&lt;br /&gt;
| '''C Shell'''-It provides features lacking in '''Bourne Shell '''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 02:16&lt;br /&gt;
| '''K Shell'''- It was created by David Korn.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 02:20&lt;br /&gt;
|It has features of both, '''B Shell''' and '''C Shell''' along with some additional features. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 02:27&lt;br /&gt;
| '''Bash Shell'''-&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 02:30&lt;br /&gt;
| The '''Bash Shell '''was developed by '''GNU Project'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 02:32&lt;br /&gt;
| It is based on '''B Shell''' language.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|02:35&lt;br /&gt;
| It has features of''' C''' and '''K Shells.'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 02:40&lt;br /&gt;
| '''TC Shell'''-It is the default '''Shell '''of '''FreeBSD '''and its descendants. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 02:46&lt;br /&gt;
| '''Z shell'''- &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|02:49&lt;br /&gt;
| It is a '''Shell''' designed for interactive use. &lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 02:52&lt;br /&gt;
|It has many useful features of '''ksh, bash''' and '''tcsh.'''&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 02:58&lt;br /&gt;
|Now let us see what a '''Bash Shell script''' is. &lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 03:02&lt;br /&gt;
|The '''Bash Shell script ''' contains a series of '''Bash''' '''commands''' in plain '''text file'''.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 03:08&lt;br /&gt;
| It tells the '''Shell''' to '''execute''' this''' text file''' instead of typing the '''commands'''. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 03:15&lt;br /&gt;
| Let us see how to write a simple '''Bash script.'''&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 03:20&lt;br /&gt;
| We will test the '''echo''' command''' which will print '''Hello World '''on the '''terminal'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 03:25&lt;br /&gt;
|Go back to the '''terminal'''.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 03:29&lt;br /&gt;
|Now, type: '''echo''' space within double quotes '''Hello  world'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|03:35&lt;br /&gt;
|and press '''Enter'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|03:37&lt;br /&gt;
| This prints '''Hello World''' on the '''terminal.'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 03:40&lt;br /&gt;
| The '''command''' worked as expected.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 03:43&lt;br /&gt;
| Now, what if we want to use this '''command''' in a file?&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 03:47&lt;br /&gt;
| Just put this '''command''' in a file and '''execute''' that file.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 03:52&lt;br /&gt;
| I will use '''gedit''' '''text-editor''' for this purpose. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 03:57&lt;br /&gt;
| You are free to use your favorite '''text-editor'''.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|04:00&lt;br /&gt;
| I want to create my file on the '''Desktop'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 04:03&lt;br /&gt;
| So, type: '''cd''' space '''Desktop'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 04:07&lt;br /&gt;
| Press '''Enter.'''&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
| 04:09&lt;br /&gt;
|Now, type: '''gedit space hello underscore world dot sh space &amp;amp;'''(ampersand sign).&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|04:20&lt;br /&gt;
|'''gedit''' is the '''text editor'''. 'Hello underscore world dot sh' is the file name and &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|04:27&lt;br /&gt;
|we use the &amp;amp; (ampersand) to free up the '''prompt'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 04:32&lt;br /&gt;
| Now press '''Enter.'''We have opened a new file named '''hello_world.sh''' using '''gedit.'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 04:40&lt;br /&gt;
| Now, type: '''hash exclamation mark front slash bin front slash bash'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 04:47&lt;br /&gt;
| This is the first line of every '''bash script'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 04:51&lt;br /&gt;
| It is called as '''shebang''' or '''bang''' line.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|04:55&lt;br /&gt;
|Press '''Enter'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 04:57&lt;br /&gt;
|Now, let's add a '''comment''' to the file by typing: &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:00&lt;br /&gt;
|'''hash space My first Bash script'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 05:06&lt;br /&gt;
| Remember that any line after '''hash''' is treated as a '''comment.'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:11&lt;br /&gt;
|And '''comments''' are ignored by the '''Bash''' '''interpreter'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 05:15&lt;br /&gt;
| Now we can add the '''command''' which we used earlier.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:19&lt;br /&gt;
|Press '''Enter''' and type: '''echo''' space within double quotes '''Hello world'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:27&lt;br /&gt;
| Press '''Enter'''.Type: '''echo space dollar-sign SHELL''' (in Capital)&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:34&lt;br /&gt;
| press '''Enter.'''Type: '''echo space backtick date backtick'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:41&lt;br /&gt;
|'''backtick''' symbol is present on the key which has '''tilde''' character.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:47&lt;br /&gt;
|Now, click on '''Save''' to save the file.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:50&lt;br /&gt;
|Let us '''execute'''. Come back to our '''terminal'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|05:55&lt;br /&gt;
| First, we have to  make the file executable.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 05:58&lt;br /&gt;
| For this, type: '''chmod''' space '''plus x''' space '''hello underscore world dot sh'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:09&lt;br /&gt;
|and press''' Enter'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:12 &lt;br /&gt;
| Now, type:&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:14&lt;br /&gt;
|'''dot slash hello underscore world dot sh'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:19&lt;br /&gt;
|Press '''Enter.'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 06:22&lt;br /&gt;
| You can see '''Hello World''' is displayed on the '''terminal'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 06:27&lt;br /&gt;
| The''' shell '''type is displayed on the next line. i.e '''slash bin slash bash'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 06:32&lt;br /&gt;
|  and day, month, time, time zone and year are displayed.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:38&lt;br /&gt;
|The '''output''' may vary depending on the system.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 06:43&lt;br /&gt;
| Let us go back to our '''slides''' and summarize.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:46&lt;br /&gt;
|In this tutorial, we have learnt about:&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:48&lt;br /&gt;
|Different types of '''Shells'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:50&lt;br /&gt;
| '''Bash Shell '''.'''Bash Shell script'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|06:52&lt;br /&gt;
|To write  a simple '''Shell script '''and to '''execute''' the script.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 06:57&lt;br /&gt;
| As an assignment- write a simple '''script''' to display the message -“'''Welcome to Bash learning'''”&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:03&lt;br /&gt;
| and''' “***************” ''' (asterisks) on separate line.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| 07:06&lt;br /&gt;
| Watch the video available at the link shown below.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:10&lt;br /&gt;
|It summarizes the Spoken-Tutorial project. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:13&lt;br /&gt;
|If you do not have good bandwidth, you can download and watch it.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:17&lt;br /&gt;
|The Spoken-Tutorial Project team: &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:20&lt;br /&gt;
|Conducts workshops using spoken tutorials. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:22&lt;br /&gt;
|Gives certificates to those who pass an online test.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:26&lt;br /&gt;
|For more details, please write to contact@spoken-tutorial.org&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:34&lt;br /&gt;
|Spoken Tutorial Project is a part of the &amp;quot;Talk to a Teacher&amp;quot; project.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:39&lt;br /&gt;
|It is supported by the National Mission on Education through ICT, MHRD, Government of India.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:45&lt;br /&gt;
|More information on this mission is available at the link shown below. http://spoken-tutorial.org/NMEICT-Intro&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:51&lt;br /&gt;
|The script has been contributed  by  FOSSEE and Spoken-Tutorial teams. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|07:56&lt;br /&gt;
|This is Ashwini Patil from IIT Bombay, signing off. Thank you for joining.&lt;br /&gt;
&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Meboreen Mary</name></author>	</entry>

	</feed>