To skip operations in UNIX shell


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting To skip operations in UNIX shell
# 8  
Old 05-02-2014
If you use a here-document construct for that, also make sure that there quotes around the first EOF ( <<"EOF" ), otherwise parameter expansion, command substitution, and arithmetic expansion will still occur within that block.
This User Gave Thanks to Scrutinizer For This Post:
# 9  
Old 05-02-2014
True, Scrutinizer. But that wouldn't hurt, would it? Except for some waste of CPU- ressourses?
# 10  
Old 05-02-2014
Quote:
Originally Posted by RudiC
True, Scrutinizer. But that wouldn't hurt, would it? Except for some waste of CPU- ressourses?
Well command substitution might hurt, depending on what is being done inside. Anyway I would not want to leave that to chance..
# 11  
Old 05-02-2014
Quote:
Originally Posted by RudiC
True, Scrutinizer. But that wouldn't hurt, would it? Except for some waste of CPU- ressourses?
Parameter substitution includes $() and backticks. It could well end up doing something...
# 12  
Old 05-02-2014
Not sure if this might be an idea...

Create a function from the __unwanted__ code:-
Code:
unused()
{
# All your temporary code here...
}

EDIT:
As a bonus if you need it you can call it...

Last edited by wisecracker; 05-02-2014 at 02:01 PM.. Reason: See above...
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Shell operations from C++

Hi everyone, I need little help in shell operations from C++ program. Here I furnish the details of problem: 1. Lets say my current working path is myWorkingPath. 2. In my working path I have list of name directories and each name directory has two more sub directories say A/B. (now path to... (5 Replies)
Discussion started by: linuxUser_
5 Replies

2. Shell Programming and Scripting

How to skip the first line of the script in shell using python?

How to skip first line of the script in shell, using python. (3 Replies)
Discussion started by: KarthikPS
3 Replies

3. Programming

shell cursor operations

Hi I need to save the actual cursor position into variable in my script. How can I do it ? thx for help. (1 Reply)
Discussion started by: presul
1 Replies

4. Shell Programming and Scripting

Unix Shell scripting -How to skip User Standard input section from another script

All, problem Description: For example: I have two shell scripts(executables). let name it as script1 and script2.I'm trying to execute script1 from script2. while executing script2, script1 is asking for manual input(input from keyboard). Now i need to know how I can skip this user input... (3 Replies)
Discussion started by: techie99
3 Replies

5. IP Networking

What is the best Unix-like for firewalling operations

Hello from France, I'd like to have your opinion on this : What unix-like would you choose for high bandwidth netwoking operations like a cluster of statefull firewalls ? NetBSD, Linux, others ? Thank you. Best regards. Vincent. (0 Replies)
Discussion started by: vrzs
0 Replies

6. Shell Programming and Scripting

Date operations in Unix?

Hi Friends, I need help in below requirements, 1. I have to get current datetime + <mins> into a variable 2. I have to compage dates like, A=01-JAN-2009 10:20:10 B=01-JAN-2009 10:30:00 C=<same format date as above> I have to find whether, 1. C is less than A OR, 2. C is greater... (7 Replies)
Discussion started by: smr_rashmy
7 Replies

7. Shell Programming and Scripting

Unix File operations

Hi, Iam having the two files as follows: file1: ASQWEDFR09876543121234512 POIUYTREW09876512345676788 ZXCVBNMKS1209888888888888 file2: ASQWEDFR09876543121234516 asdcvfgbtg@abc.com 0000000-90-1239--2008 8990---- CXADFGTU09876543121234789 asdcvfgbtg@abc.com ... (14 Replies)
Discussion started by: nivas
14 Replies

8. Shell Programming and Scripting

Unix file operations(shell script)

Hi, I want to compare two files. Files will look like as follows: file1: ASDFGHJU|1234567890123456 QWERTYUI|3456789098900890 file2: ZXCVBVNM|0987654321234567 POLKIJUYH|1234789060985478 output file should be: ASDFGHJU|1234567890123456 QWERTYUI|3456789098900890 Thnaks in advance (6 Replies)
Discussion started by: nivas
6 Replies

9. UNIX for Dummies Questions & Answers

mathematics operations in unix

Hello guys! Can say me anybody about operatios with unix, I don't to make operations, only inside in a variable, like this #y=4 #x=2 #let z=$y-$x #echo $z # 2 but I can't to make mathematical operations with decimal like this #y=3.2 #x=1.5 #let z=$y-$x #echo $z # 3 this... (2 Replies)
Discussion started by: cesar720213
2 Replies
Login or Register to Ask a Question