-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add os.getCacheDir
#18126
add os.getCacheDir
#18126
Conversation
6c489df
to
79e66c9
Compare
79e66c9
to
ffa96d7
Compare
when defined(windows): | ||
getCacheDir() / app / "cache" | ||
else: | ||
getCacheDir() / app |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that just the 1st overload is Ok, the user can make getCacheDir() / "app"
themselves, but is just my opinion...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
that would not be correct for windows; that's the point of this proc, make it portable (other libraries do this too)
PTAL |
deea8ce
to
21b88dd
Compare
* add `os.getCacheDir` * fixup * address comments
from reading at various reference materials, this seems like the most commonly accepted setting overall
example use case
nimdigger
: build nim at any revision since v0.12.0~157, 1 linergit bisect
to help find regressions #18119) can use this instead of polluting user home with ~/.nimdigger (which is usually for config files, not cache data)~/.cache/nim
which is a non-standard location on osx for eg)links