Hack Forums
Bash scripting help - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Computing (https://hackforums.net/forumdisplay.php?fid=88)
+---- Forum: Linux (https://hackforums.net/forumdisplay.php?fid=85)
+---- Thread: Bash scripting help (/showthread.php?tid=4790146)



Bash scripting help - cewa - Apr 22, 2015

Hello,

I am learning bash scripting in centos 6, and i was searching internet and didnt found good tutorials that have tasks with answers.
If someone can give me a good tutorial i can practice and easy for newbies

Thanks


* - Betty Blue - Apr 22, 2015

(Apr 22, 2015 07:52 AM)cewa Wrote:  Hello,

I am learning bash scripting in centos 6, and i was searching internet and didnt found good tutorials that have tasks with answers.
If someone can give me a good tutorial i can practice and easy for newbies

Thanks
The Linux Command Line
This book has a decent section on BASH, it also covers lots about expansion and regular expressions, and goes over sed and awk.


* - cewa - Apr 22, 2015

Thank you so much i will check all your links


* - .Switch - Apr 22, 2015

This is the tutorial I used.

There's also an advanced guide on the same site:

Advanced Bash-Scripting Guide

Or were you looking to achieve something more specific?


* - cewa - Apr 24, 2015

Thank you kind sir ! I think i will learn this somehow :D


* - dotslash - Apr 25, 2015

Checkout "the Linux Bible" it has bash basics for beginners


* - datguy.dev - Apr 25, 2015

In addition to what other have suggested, why not post a description of an action that you want to accomplish w/ Bash. We maybe able to can walk you through the syntax.


* - cewa - Apr 26, 2015

My goal is to learn bash I am now a newbie i started learning how to write scripts i just wrote few of them like compare 2 numbers , find if user exists and so one. I want to get better at that because i want a job in that area so that is what i want to accomplish


* - datguy.dev - Apr 26, 2015

(Apr 26, 2015 06:27 AM)cewa Wrote:  My goal is to learn bash I am now a newbie i started learning how to write scripts i just wrote few of them like compare 2 numbers , find if user exists and so one. I want to get better at that because i want a job in that area so that is what i want to accomplish

Well good luck on your journey.

If your ooking to expand your knowledge on the subject, try comparing floating numbers using redirection and a program such as 'bc'. (>>>) If you can figure that out, you're pretty much set outside of formatting things. Then again, Bash isn't a strong language.

a="123456789"; a=${a:(-3)}; echo $a;


* - cewa - Apr 27, 2015

(Apr 26, 2015 09:06 AM)datguy.dev Wrote:  Well good luck on your journey.

If your ooking to expand your knowledge on the subject, try comparing floating numbers using redirection and a program such as 'bc'. (>>>) If you can figure that out, you're pretty much set outside of formatting things. Then again, Bash isn't a strong language.

a="123456789"; a=${a:(-3)}; echo $a;

Thanks for task :D i will try to do it