Forum     

Go Back   Digit Technology Discussion Forum > Software > Open Source
Register FAQ Calendar Mark Forums Read

Open Source A place where you can talk to like-minded people about the fastest growing software movement today! Discuss anything and everything about Open Source software and Operating Systems.


Closed Thread
 
LinkBack Thread Tools Display Modes
Old 30-06-2006, 08:18 PM   #1 (permalink)
Right Off the Assembly Line
 
Join Date: Apr 2006
Posts: 4
Lightbulb tricky ques


1) can you create a file in linux with name as x/y: containing a '/'.

2) does this still works:
echo date is 'date'
and we get output as
date is <date/time here>
ravix is offline  
Advertisements. Register and be a member of the community to get rid of them.
Advertisement

Old 30-06-2006, 08:27 PM   #2 (permalink)
GaurishSharma.com
 
gary4gar's Avatar
 
Join Date: May 2005
Location: Jaipur
Posts: 4,116
Default Re: tricky ques

oops!! my bad

Last edited by gary4gar; 30-06-2006 at 09:41 PM.
gary4gar is offline  
Old 30-06-2006, 09:14 PM   #3 (permalink)
Wise Old Owl
 
JGuru's Avatar
 
Join Date: Dec 2005
Location: Space-time continuum
Posts: 1,646
Default Re: tricky ques

I think this not a tips & tricks solution!! @Ravix is just asking an answer for his
question. Since this is a Open-Source related question it can be at 'Open Source'
section. Since it's not a Tips n Tricks solution , no need to move this thread!!
JGuru is offline  
Old 01-07-2006, 09:56 AM   #4 (permalink)
Alpha Geek
 
Satissh S's Avatar
 
Join Date: Mar 2005
Location: Chennai , India
Posts: 693
Default Re: tricky ques

@ravix:

1. No it was not possible to create the file f/g, eg. if i type
# emacs f/g
it opens the file g within a unknown directory f in the buffer but it only saves the file inside directory 'f' once i issue 'mkdir f'. This is understandable as directories are container files and to the filesystem a file say my_coolmp3.mp3 within the music directory is a file with actual name as /home/user/music/my_coolmp3.mp3. Atleast thats my understanding of the file system concepts. someone correct if wrong.

Also a file may have several hardlinks to a file so maybe its one of the hardlinks. But a file gets deleted only when the last possible hardlink is deleted.

2. the output i get for the stanzas,
$ echo date is 'date'
date is date
$ echo 'date is 'date''
date is date
$ echo date is date
date is date
$echo 'date is date'
date is date
are all the same.
__________________
Call it Emacs,
Love it or Leave it.
Satissh S is offline  
Old 02-07-2006, 05:43 AM   #5 (permalink)
Wise Old Owl
 
vignesh's Avatar
 
Join Date: Jul 2004
Location: Chennai
Posts: 1,659
Default Re: tricky ques

You can use this ...

vignesh@linux-dm4c:~> echo date is $(date)
date is Sun Jul 2 05:41:35 IST 2006
vignesh is offline  
Old 02-07-2006, 01:42 PM   #6 (permalink)
FooBar Guy
 
GNUrag's Avatar
 
Join Date: Jun 2004
Location: GNUmbai
Posts: 1,245
Default Re: tricky ques

You can use this however,
$ echo date is `date`
date is Sun Jul 2 13:41:32 IST 2006

Note that those are back ticks ` . Adding a back tick `command` is equivalent to $(command)
__________________
- --
http://web.gnuer.org
GNUrag is offline  
Closed Thread

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


 
Latest Threads
- by topgear

Advertisement




All times are GMT +5.5. The time now is 08:49 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.

Search Engine Optimization by vBSEO 3.3.2