variable name with dot(.)


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers variable name with dot(.)
# 1  
Old 03-11-2009
variable name with dot(.)

Hi,

Is it possible to declare variable with name having dot(.) in it ?

something like gs.test='HELLO'

Thanks in advance Smilie
# 2  
Old 03-11-2009
Just try it out, you will get an error. It is better to use an underscore for example to increase readability.

Maybe there are some shells that allow them though, idk. Better keep it with underscores also for portability I think.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Mv or cp with a . (dot)?

How can I rename a file with a . prefix? I actually need to copy the file but the . seems to be very tough to do. mv ./bla ../fa/la/.bla - doesn't work. I've tried all sorts of bracketing and that doesn't work. Maybe the only way to do it would be to name the file _.bla then rename it... (19 Replies)
Discussion started by: scribling
19 Replies

2. Shell Programming and Scripting

Create polygon around dot

Dear Masters, Kindly need your help to solve my issue.. My goal is create a polygon around "dot" (x,y coordinate) lets say we have some dot as below (these coordinates have meter as unit) 588237.20 5768355.50 588337.90 5768402.50 588459.70 5768436.00 588584.30 ... (7 Replies)
Discussion started by: ipatah
7 Replies

3. Programming

How to put dot(.) in a string in C?

Hi all, Can anybody please tell me how can I put dot(.) in a string using C programming. for example -- I am having string "10111988" and I want to convert it as "10.11.1988" I will appriciate and thanks in advance.. (4 Replies)
Discussion started by: smartgupta
4 Replies

4. Shell Programming and Scripting

how to remove a variable starting with dot using sed command

Hi, I want to remove a variable starting with dot(.) in a file using sed command. aaa sss .abc s/^\.abc/d I tried this but it didnt worked. (5 Replies)
Discussion started by: vdhingra123
5 Replies

5. Shell Programming and Scripting

How to Removing a dot from a file name?

I need a script that will allow me to rename all of my files in subdir /FilesIn as follows: From kumc_835_111200.RMT.dat to kumc_835_111200RMT.dat kumc_835_111200.KMR.dat to kumc_835_111200KMR.dat .................etc How do I do that whithout doing a sed ... (10 Replies)
Discussion started by: mrn6430
10 Replies

6. Shell Programming and Scripting

use dot file in linux

Hi, I am creating a phonebook to store the name:phone:address.The phonebook is used to store, edit,delete and list the data. Now i need to use text file(dot files) for configuration (saving and loading selections). I really don't know how to do that. Please help thanks.. (6 Replies)
Discussion started by: coolgal
6 Replies

7. Shell Programming and Scripting

removing DOT by using perl

Hi Friends, I have a variable which has a number (e.g. 12.1234). I want to remove "." (dot) from that number i.e. 121234 I want to do this using perl. Can you please guide me Thank you Anushree (2 Replies)
Discussion started by: anushree.a
2 Replies

8. Shell Programming and Scripting

splitting on dot in perl

I am trying to split input that looks like ,2005-09-12 01:45:00.000000,2005-09-12 01:48:18.000000, I want to split on the dot . What I am using is ($ev_time,$rol)=split(/\./),$inputfile; This does not recognize the dot as what I want to split on. (2 Replies)
Discussion started by: reggiej
2 Replies

9. Shell Programming and Scripting

dot files

Hi, everyone. I'm now using rsync command, and please tell me what is the wildcard for below looks like. I want to chose dotfiles, such as .ipod .apple but i don't want to chose . and .. ------------------ .* doesn't work, of course. Thanks, Euler04 (2 Replies)
Discussion started by: Euler04
2 Replies
Login or Register to Ask a Question