5 important things to follow to become good in shell scripting

简介: http://unix-school.blogspot.in/2011/07/5-important-things-to-follow-to-become.

http://unix-school.blogspot.in/2011/07/5-important-things-to-follow-to-become.html

Everybody wants solutions to their problems, and more importantly,  we are now expected to get it faster. One can give faster solutions in Unix when one has a good grip on the command line options, and more importantly scripting languages. There are quite a few of them present: Basic Shell scripting, perl scripting, python, ruby, etc. Though our title reads to become good in shell scripting, we in general are going to discuss how to become good in automating things? Or the kind of outlook one needs to have to go in that direction?

    How can one become good in automation? Is it just books one has to read and master or something more? Let us see in this article 5 different traits if one has can turn things around:


1 . Be lazy: The most important trait of all is, to be lazy, to be absolutely lazy. Please don't read between the lines. Being lazy means to show laziness to do the same things repetitively.  The more lazy you are, the more you start disliking tasks of such nature which demand you to grind the same stuff day-in and day-out.  Gradually, you start thinking towards a solution which will get the job done easily, which will achieve the same result with lesser effort which in turn will lead you to automation.  Keep in mind, the world tomorrow is for those who do things better and more importantly, faster.

2. Learn scripting languages: One can give many tips to follow to evince interest in automation, however at the end of the day, it is the individual's choice to show interest in what he or she is doing. We need to be very interested in making things simpler, which makes our life comfortable. Once you start showing interest, you will start doing all the right things such as learning different automation stuffs in UNIX like basic shell scripting, sed, awk, perl, python, ruby,etc. Once you have learnt a scripting language, look out for some potential things or tasks in your project which can be automated. Once you automate something, you will understand the real joy and power behind automation.

3. Pay attention to the smallest of things: An employee's mantra should always be: Make life simple for others.When you are in an organization, you might be in an environment where you will find quite a few things which can be automated. In this case, you have lot of scope for automation. However, it is also possible where you find everything has been automated already in your project, nothing else left or no scope for any more automation. I personally do not accept the fact that there is no scope for automation in any project. The thing you should keep in mind is: Be aware and pay fullest attention to the smallest of things. There are many many things which without realizing we keep doing again and again. Even though it is small, if automated will lead to a considerable time saving. The point I am trying to make is: You need not sit and think what can I automate in my work place. Just pay attention to your day to day activities, you will get hundreds of places where you can automate.

4. Participate in forums: Say, you learnt some scripting language, say shell scripting or perl scripting. If you are working in an environment where you get work on scripting on a regular basis, no issues. However, this may not be the case everywhere or for everybody. Sometimes, you may get a scripting task once in a blue moon, and by the time the next task comes, we have forgotten what we learnt. Due to this, we are in need wherein we need to be continuously in touch with what we have learnt. And the best way to do this is by participating in forums. Everyday, one should spend atleast half-an-hour in a forum. For Unix people, I will always prefer unix.com .

   Participating in forums is not just to remain in touch.  Keep in mind, for every problem, there is more than one way of solving it. The real meaning of this statement you will realize when you participate in any forum. Even for some simplest of problems, you will see most beautiful solutions. And when you see a particular problem being approached in many different ways, your thinking towards a problem starts differing, starts getting multiple options. Also, the kind of learning which will happen here is something which you may not come across in any text book.

5. Develop a never repeating mindset: Tell yourself you will never do the same thing again. If you are doing the same thing again and again,  something is going wrong. Once you develop a mindset of this nature, you will automatically be more inclined towards automation or scripting. Think of ways which will minimize the effort, reduce the time needed to perform it. Any time you get something which you had done before, ask yourself one question: "How can I do it better than last time?". Next time, when you get it again, ask yourself: "What can I do so that I need not repeat the whole thing again next time?"

Happy Automating!!!

 

目录
相关文章
|
Unix Shell Perl
5 important things to follow to become good in shell scripting
http://unix-school.blogspot.in/2011/07/5-important-things-to-follow-to-become.
1030 0
|
Unix Shell Go
10 good shell scripting practices
http://unix-school.blogspot.in/2011/07/5-important-things-to-follow-to-become.
874 0
|
Unix Shell Perl
5 important things to follow to become good in shell scripting
http://unix-school.blogspot.in/2011/07/5-important-things-to-follow-to-become.
995 0
|
23天前
|
弹性计算 Shell Perl
ecs服务器shell常用脚本练习(二)
【4月更文挑战第1天】shell代码训练(二)
106 1
|
26天前
|
Java Shell
SpringBoot启动脚本Shell
SpringBoot启动脚本Shell
17 0
|
3天前
|
Java 关系型数据库 MySQL
Elasticsearch【问题记录 01】启动服务&停止服务的2类方法【及 java.nio.file.AccessDeniedException: xx/pid 问题解决】(含shell脚本文件)
【4月更文挑战第12天】Elasticsearch【问题记录 01】启动服务&停止服务的2类方法【及 java.nio.file.AccessDeniedException: xx/pid 问题解决】(含shell脚本文件)
28 3
|
6天前
|
运维 监控 Shell
利用Shell脚本编写局域网监控软件:实时监测主机连接情况
本文介绍了如何使用Shell脚本创建一个局域网监控工具,以实时检查主机连接状态。脚本包括扫描IP地址范围检测主机可达性及使用`netstat`监控ESTABLISHED连接。此外,还展示了如何每60秒将连接数数据自动提交到指定网站API,以便实时跟踪网络活动。这个自动化监控系统有助于提升网络安全性和故障排查效率。
26 0
|
7天前
|
Shell
Shell脚本之流程控制语句
Shell脚本之流程控制语句