Skip to content

GetPathSeparator()

The GetPathSeparator function returns a string with the path separator for the operating system.

This function does not accept any arguments.

  • String:
    The string is a single character indicating the path separator based on the operating system.

This example prints the path separator:

Copy CodeLua
```
return function()
--- This prints the path seperator. It is different between a Linux and macOS (/) and a Windows (\) operating system.
Printf("The path seperator is " .. GetPathSeparator())

end