Created
March 29, 2018 18:15
-
-
Save un-def/e2d9b4460c5f220d19314c5b878290df to your computer and use it in GitHub Desktop.
get_basename lua snippet
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local get_basename = function(path) | |
return path:match('/([^/]*)$') or path | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment