<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Tuts4Tech &#187; basic</title>
	<atom:link href="http://tuts4tech.net/tag/basic/feed/" rel="self" type="application/rss+xml" />
	<link>http://tuts4tech.net</link>
	<description>Tech Tutorials</description>
	<lastBuildDate>Tue, 04 May 2010 20:35:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Basic Batch Scripting</title>
		<link>http://tuts4tech.net/2009/06/24/basic-batch-scripting/</link>
		<comments>http://tuts4tech.net/2009/06/24/basic-batch-scripting/#comments</comments>
		<pubDate>Wed, 24 Jun 2009 15:51:26 +0000</pubDate>
		<dc:creator>Duffy</dc:creator>
				<category><![CDATA[Windows]]></category>
		<category><![CDATA[basic]]></category>
		<category><![CDATA[batch]]></category>
		<category><![CDATA[notepad]]></category>
		<category><![CDATA[scripting]]></category>
		<category><![CDATA[short]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://tuts4tech.net/?p=355</guid>
		<description><![CDATA[Introduction So first of all what is batch file? Its a file with a list of commands that are executed by command prompt(CMD) to open your cmd window go to start &#62; run &#62; cmd Basic Commands [batch]@echo off[/batch] This removes the "C:\Documents and Settings\Administrator&#62;" part [batch]cls[/batch] This clears all writing off the CMD window [...]]]></description>
			<content:encoded><![CDATA[<h3>Introduction</h3>
<p><img src="http://tuts4tech.net/wp-content/uploads/2009/06/cmd.jpg" alt="cmd" title="cmd" width="500" height="253" class="aligncenter size-full wp-image-577" /><br />
So first of all what is batch file? Its a file with a list of commands that are executed by command prompt(CMD) to open your cmd window go to start &gt; run &gt; cmd</p>
<h3>Basic Commands</h3>
<ol>
<li>
[batch]@echo off[/batch]<br />
This removes the "C:\Documents and Settings\Administrator&gt;" part</li>
<li>
[batch]cls[/batch]<br />
This clears all writing off the CMD window</li>
<li>
[batch]color backgroundcolor-textcolor[/batch]<br />
This allows you to change the color of the text</p>
<pre class="brush: plain; title: ; notranslate">0 = Black       8 = Gray
1 = Blue        9 = Light Blue
2 = Green       A = Light Green
3 = Aqua        B = Light Aqua
4 = Red         C = Light Red
5 = Purple      D = Light Purple
6 = Yellow      E = Light Yellow
7 = White       F = Bright White</pre>
<p>Example command:<br />
[batch]color 04[/batch]<br />
This example would give you red text on a black background</li>
<li>
[batch]goto TEXT[/batch]<br />
This will cause the script to go to a particular section of the script it will be explained more later on in this tutorial</li>
<li>
[batch]pause[/batch]<br />
This Pauses the command prompt and displays the message press any key to continue...</li>
</ol>
<p><span id="more-355"></span></p>
<h3>Your first batch script</h3>
<p>For this example we will make a simple hello world script.</p>
<p>To get started open up notepad start &gt; all programs &gt; accessories &gt; notepad<br />
[batch]@echo off<br />
color 64<br />
echo hello world<br />
pause[/batch]<br />
Save it with a .bat extension and then double click on it to run it. It should print the text "hello world" in red font on a yellow background and then pause</p>
<h3>The goto command</h3>
<p>The goto command tells the script to go to a certain part of it<br />
[batch]goto bush[/batch]<br />
this will cause the script to go to the line that starts with<br />
[batch]:bush[/batch]<br />
Example:<br />
[batch]@echo off<br />
echo Hello, this script will repeat the message "you will see this over and over again" to cancel it press ctrl+c<br />
pause<br />
:bush<br />
echo you will see this over and over again<br />
goto bush[/batch]<br />
The message was repeated because after it was printed the goto command made the script start again from :bush</p>
<h3>Launching programs from a batch script</h3>
<p>Using the start command we can start programs</p>
<p>Example:<br />
[batch]@echo off<br />
color f1<br />
echo this script will open google.com in your default internet browser<br />
pause<br />
start http://www.google.com[/batch]</p>
]]></content:encoded>
			<wfw:commentRss>http://tuts4tech.net/2009/06/24/basic-batch-scripting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Linux Basic Commands</title>
		<link>http://tuts4tech.net/2009/05/06/linux-basic-commands/</link>
		<comments>http://tuts4tech.net/2009/05/06/linux-basic-commands/#comments</comments>
		<pubDate>Wed, 06 May 2009 15:25:42 +0000</pubDate>
		<dc:creator>Duffy</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[basic]]></category>
		<category><![CDATA[learner]]></category>
		<category><![CDATA[learning]]></category>
		<category><![CDATA[newbie]]></category>
		<category><![CDATA[noob]]></category>

		<guid isPermaLink="false">http://tuts4tech.co.cc/?p=178</guid>
		<description><![CDATA[Starting and Stopping poweroff will shutdown the system reboot will restart the system Mounting and unmounting fdisk -l gives a list of all drives mount /dev/hdd /mnt would mount the hard drive in /mnt umount /dev/hdd would unmount the hard drive Moving, copying, deleting &#038; viewing files ls will output all the files in the [...]]]></description>
			<content:encoded><![CDATA[<ol>
<h4>Starting and Stopping</h4>
<li>poweroff will shutdown the system</li>
<li>reboot will restart the system</li>
</ol>
<ol>
<h4>Mounting and unmounting</h4>
<li>fdisk -l gives a list of all drives</li>
<li>mount /dev/hdd /mnt would mount the hard drive in /mnt</li>
<li>umount /dev/hdd would unmount the hard drive</li>
</ol>
<ol>
<h4>Moving, copying, deleting &#038; viewing files</h4>
<li>ls will output all the files in the current directory</li>
<li>rm filename will remove the file</li>
<li>rm -r dir will remove the dir</li>
<li>cp filename /home/dirname this will copy the file to /home/dirname</li>
<li>mv filname /home/dirname this will move the file to /home/dirname</li>
<li>cat filetoview this will display the file called filetoview</li>
<li>man -k keyboard this will display man pages containing <keyboard></keyboard></li>
<li>tail filetoview this will display the last 10lines of the file called filetoview</li>
</ol>
<ol>
<h4>User Administration</h4>
<li>adduser accountname this will create a new users called accountname</li>
<li>password accountname this will give accountname a new password</li>
<li>su this will allow you to login as root from your current login</li>
</ol>
<ol>
<h4>Misc</h4>
<li>ifconfig this will list ip addresses for all devices on the machine</li>
<li>tail -f /var/log/messages this displays the last 10 lines of the system log</li>
<li>/etc/init.d/daemon-name-here start this will start the specified daemon</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://tuts4tech.net/2009/05/06/linux-basic-commands/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

