forked from dimo414/bkt
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support configuring the TTL, scope, and cache dir via environment
variables in addition to flags. I opted not to add an environment variable for --stale at this time because I'm not convinced how useful it would be. It's easy enough to add in the future, though I would prefer a more descriptive name than BKT_STALE if it's added. BKT_CACHE_DIR serves a very similar purpose to BKT_TMPDIR which was added in 77c5d91. I decided to use a separate variable to more directly mirror the --cache-dir flag. Notably, BKT_TMPDIR is respected by the bkt library whereas BKT_CACHE_DIR is only evaluated at parse time in the binary. In the future these variables might also have slightly different behavior, e.g. bkt might create a different directory heirarchy if BKT_TMPDIR is set instead of BKT_CACHE_DIR. Credit to @JulienPalard for the idea in dimo414#15.
- Loading branch information
Showing
4 changed files
with
44 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters