.bam/path.lua: Adding ModuleRelative()
This commit is contained in:
parent
c2c201c9e4
commit
c83337b6a6
1 changed files with 5 additions and 0 deletions
|
|
@ -4,6 +4,11 @@ function ModuleDir()
|
|||
return PathDir(ModuleFilename())
|
||||
end
|
||||
|
||||
-- Strip ModuleDir() of the beginning of path
|
||||
function ModuleRelative(path)
|
||||
return string.gsub(path, "^" .. ModuleDir() .. "/", "")
|
||||
end
|
||||
|
||||
-- Make the path relative to the current working directory
|
||||
-- and ModuleDir()
|
||||
function RelPath(path)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue