Daniel Hahler
f8a9942968
Set DOTENV_LOOK_UPWARDS=1 by default
...
Fixes https://github.com/Tarrasch/zsh-autoenv/issues/3
2014-11-16 12:35:17 +01:00
Daniel Hahler
64bbb2f305
doc / small refactoring according to feedback
2014-11-16 11:39:10 +01:00
Daniel Hahler
71ed15679b
_dotenv_source: use 'builtin cd' and stored dir instead of 'cd -'
2014-11-15 17:29:36 +01:00
Daniel Hahler
a37b0bc3f5
Wrap sourcing in _dotenv_source: chdir and set _dotenv_cwd=$PWD
2014-11-15 16:09:37 +01:00
Daniel Hahler
d114d0a0ea
Check for file existence in _dotenv_check_authorized_env_file
2014-11-15 16:09:02 +01:00
Daniel Hahler
4662727a22
Cleanup, and fixes (absolute path for env_file)
2014-11-15 15:48:57 +01:00
Daniel Hahler
4676713bc6
Various improvements
...
- Support for leave event, via DOTENV_FILE_LEAVE and _dotenv_event (can
use DOTENV_FILE_LEAVE=$DOTENV_FILE_ENTER).
- Support for searching upwards for $DOTENV_FILE_ENTER (#3 ).
- Source .env only once per session, but re-source when leave events
are enabled (#1 ).
- Trigger the machinery when the script gets sourced, for the current
dir (#2 ).
2014-11-15 15:08:52 +01:00
Daniel Hahler
41625bf31c
Use 'local' in functions
2014-11-15 14:49:48 +01:00
Daniel Hahler
1e60c98e4a
Use escaped grep command, skipping aliases
2014-11-15 13:59:42 +01:00
Arash Rouhani
08fec15f31
Add tests
2013-09-08 18:32:16 +02:00
Arash Rouhani
fce22b3c41
Add source file
2013-09-08 17:06:26 +02:00