question about brackets ()


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers question about brackets ()
# 1  
Old 03-08-2009
Data question about brackets ()

Hello guys, I'm brand new to UNIX. I've installed Cygwin as recommended, but here are some problems. Well, man command doesn't work and I also don't know how to create a file or even how to type (). With () the program gives me an error message. Please tell me how to do all these things. Best regards, Wade
# 2  
Old 03-08-2009
What shell are you using? Did man ever get installed? Did you install any sort of editor? What program gives you what error message when you type ()?
# 3  
Old 03-08-2009
Since you are really confused let's try:
1. type in the commands exactly as given below- to type a command use lowercase, press the ENTER key at the end of the line - note: the words in uppercase HAVE to be uppercase. The $ is required in front of $SHELL.
Code:
echo $SHELL
which man

2. Next, copy the results (or transcribe them) and post them here so we can see the results.

and with regard () all by itself like that - it is two characters: open paren ( and close paren ). As you wrote it, for most shells (what the $SHELL thing shows) ( ) does nothing. Those characters are shift-9 and shift-0 on most keyboards.
# 4  
Old 03-09-2009
done

echo $SHELL
/bin/bash

which man
/usr/bin/man
# 5  
Old 03-09-2009
Did you install any sort of editor? What program gives you what error message when you type ()?
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Capture the value between brackets

Hi I am having hard time getting this right and need some help. I Have 3 files, and everyone contains the following:- File1 Today, we have Name(Jack) Age(19) Class (A2) Today, we have Name(Kim) Class (G9) File2 Today, we have Name(Lee) Age(19) Class (A2) Today, we have... (8 Replies)
Discussion started by: samsan
8 Replies

2. Shell Programming and Scripting

Brackets

Hi all. i need a small help. i have written an exit code, which will check whether mo.sh is successful or not. if the status is >0 it will exit the shell. 1>Do you guys think it is a correct way to write? 2>what if i change the double bracket to single. how will it change the o/p. ... (1 Reply)
Discussion started by: sub
1 Replies

3. Shell Programming and Scripting

Delete text between square brackets and also delete those square brackets using sed or awk

Hi All, I have a text file which looks like this: computer programming systems engineering I want to get rid of these square brackets and also the text that is inside these brackets. So that my final text file looks like this: computer programming systems engineering I am using... (3 Replies)
Discussion started by: shoaibjameel123
3 Replies

4. Shell Programming and Scripting

How to get the value in the first brackets

Hello, I am trying to write a script using ksh. And I want to get the value within the first brackets of a string. For example: 14/04/11 11:35: 00 This is (nn) from the earth. Then i hope to get nn in this case. Can any one advise me how to implement it? Thank you very much! nn (2 Replies)
Discussion started by: n_n
2 Replies

5. Shell Programming and Scripting

Get value between brackets

Hi I am having hard time getting this right and need some help. I Have several log files, and everyone contains the following 3 lines at the end: 4 ETW000 Disconnected from database. 4 ETW000 End of Transport (0000). 4 ETW000 date&time: 13.01.2011 - 08:03:28 I need to capture the value... (7 Replies)
Discussion started by: nimo
7 Replies

6. Shell Programming and Scripting

Double square brackets question

Hi, I just came across an interesting shell script syntax like the one below: ] && (trap 'rm -rf ${WORK_DIR}/*.$$; echo "\n\nInterrupted !!\n\n"; exit 4' 1 2 3 15) Can someone please explain the code snippet above? The trap command bit is fine but ] && is the hazy part. Generally we use an... (2 Replies)
Discussion started by: King Nothing
2 Replies

7. Shell Programming and Scripting

How to apply brackets?

Hi, I have a query term like this: $query="apple NOT banana AND fruits"; $query="a1 NOT prim1 AND a2 NOT a3 OR a5"; I want to apply brackets to the NOT terms and the output should be like this: $query="apple NOT (banana) AND fruits"; $query="a1 NOT (prim1) AND a2 NOT (a3) OR a5";... (2 Replies)
Discussion started by: vanitham
2 Replies

8. Shell Programming and Scripting

help to delete brackets [ ]

hi all, i want to delete brackets in all the file and to keep the string or data between them ( example Q --> Qxxx) with sed command.. thanks (4 Replies)
Discussion started by: kamel.seg
4 Replies

9. Shell Programming and Scripting

how do you use brackets ?? in a script.

:D i am pretty much new to scripting and don't want to pick up bad habits so I am trying to get myself to use brackets in my scripts since I plan on using them alot.. ! in this example of a script I wrote I can not figure out where the brackets go can anyone give me some insight into the use of... (3 Replies)
Discussion started by: moxxx68
3 Replies

10. UNIX for Dummies Questions & Answers

square brackets

I would like to substitute a phrase which contains square brackets. change TO how? Thanks (2 Replies)
Discussion started by: gilead29
2 Replies
Login or Register to Ask a Question