News : The level of daily SPAM has reached insane proportions, all registrations are now manual. I ask you to send me an e-mail (john (at) murga (dot) org), to confirm that you want me to create an account for you.

Post Reply  Post Thread 
Function to return the current directory
Author Message
Senior Member

Posts: 522
Group: Registered
Joined: Apr 2007
Status: Offline
Reputation: 5
Post: #1
RE: Function to return the current directory

There is an lfs example included (examples/tests), which looks like it is the same one distributed with lfs (which is also found in the 3rd-party directory).
The first function in that file appears to contain a test of this nature:

if attr.mode == "directory" then

Now I haven't tried this yet, but going by that example, and the lfs documentation, the table created by lfs.attributes ("attr" in this example) contains the attribute named "mode", which returns the string file, directory, link, socket, named pipe, char device, block device or other

08-01-2007 06:57 AM
Find all posts by this user Quote this message in a reply
Post Reply  Post Thread 

Messages In This Thread
RE: Function to return the current directory - mikshaw - 08-01-2007 06:57 AM

View a Printable Version
Send this Thread to a Friend
Subscribe to this Thread | Add Thread to Favorites

Forum Jump: