Module molly.utils
Helpers.
Functions
setenv (key, value) | Set and unset environment variable. |
cwd () | Get current directory. |
chdir (dir) | Change current directory. |
is_tarantool () | Defines whether we run under Tarantool. |
basename (path) | Function equivalent to basename in POSIX systems |
pack () | Packs the given arguments into a table with an n key
denoting the number of elements. |
Functions
- setenv (key, value)
-
Set and unset environment variable.
Parameters:
Returns:
-
true
Raises:
error - cwd ()
-
Get current directory.
Returns:
-
string, absolute path to a current directory
- chdir (dir)
-
Change current directory.
Parameters:
- dir string
Returns:
-
boolean
- is_tarantool ()
-
Defines whether we run under Tarantool.
Returns:
-
boolean
- basename (path)
-
Function equivalent to basename in POSIX systems
Parameters:
- path string
Returns:
-
string
- pack ()
-
Packs the given arguments into a table with an
n
key denoting the number of elements.Returns:
-
table