[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: directory separator?
- From: PA <petite.abeille@...>
- Date: Wed, 12 Jul 2006 14:14:57 +0200
What would be a reasonable way to guess the directory separator (e.g. /
or \) from a Lua script?
Presently, I'm parsing the package.path, but perhaps there is a more
reliable way to achieve this?
print( package.path:match( "(%p)%?%." ) )
I noticed a LUA_DIRSEP in luaconf.h. Is that accessible from a Lua
script? Some of this information seems to be pushed into package.config
Would it be reckless to rely on this undocumented (?) package.config