https://github.com/robloach/wren-path
Work with file and directory paths in Wren.
https://github.com/robloach/wren-path
Last synced: 4 months ago
JSON representation
Work with file and directory paths in Wren.
- Host: GitHub
- URL: https://github.com/robloach/wren-path
- Owner: RobLoach
- License: mit
- Created: 2021-05-02T00:45:48.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2021-05-31T15:46:50.000Z (about 5 years ago)
- Last Synced: 2025-07-24T02:29:54.349Z (11 months ago)
- Size: 4.88 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# wren-path
Utility class for the [Wren scripting language](https://wren.io) to work with file and directory paths.
## Usage
``` js
import "path/to/wren-path/Path" for Path
Path.basename("path/to/something.txt") // => something.txt
Path.extname("something.txt") // => .txt
Path.isAbsolute("/path/to/something.txt") // => true
Path.dirname("/path/to/something.txt") // => /path/to
Path.normalize("path/to/other/../something.txt") // => path/to/something.txt
```
## Testing
```
git submodule update --init
wren_cli test.wren
```