https://github.com/gregoryv/working
Package working provides types for file system operations within a directory.
https://github.com/gregoryv/working
Last synced: 11 months ago
JSON representation
Package working provides types for file system operations within a directory.
- Host: GitHub
- URL: https://github.com/gregoryv/working
- Owner: gregoryv
- License: mit
- Created: 2020-02-16T07:17:18.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-02-18T01:35:02.000Z (over 6 years ago)
- Last Synced: 2025-06-28T09:39:21.948Z (12 months ago)
- Language: Go
- Homepage:
- Size: 1.02 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: changelog.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://travis-ci.org/gregoryv/working)
[](https://codecov.io/gh/gregoryv/working)
[working](https://godoc.org/github.com/gregoryv/working) - Package defines Directory type for easy file operations
This package is most useful if you need to do multiple file operations
within one directory. Eg. something like
cd /tmp/dir
mkdir child1 child2
touch child1/A child2/B
# do some stuff
cd
rm -rf /tmp/dir
Using this package you would
d := new(working.Directory)
d.SetPath("/tmp/dir")
d.MkdirAll("child1", "child2")
d.TouchAll("child1/A", "child2/B")
// do stuff
d.RemoveAll()