Getting started with 1Password for your growing team, or refining your setup? Our Secured Success quickstart guide is for you.
Forum Discussion
Former Member
4 years ago[69] combine new CLI with direnv or similar tools?
Currently, I use a tool called https://direnv.net/ to set environment variables when I enter a directory in my terminal.
here's what I would like to achieve:
Have an .envrc file in my directo...
Former Member
4 years ago@"Justin.Yoon_1P" I didn't like starting another shell from my .envrc
file (as that might also cause some infinite loops I guess as the next time I switch to that directory it would try to reload the .envrc
), so here's my quick (and ugly) fix for now. I am losing out on the masking by op run
, but I don't have to do anything manually when I go to the directory anymore.
Maybe it helps someone else:
```sh
eval $(cat <<EOF |
export MY_USERNAME="op://prod/account/username"
export MY_PASSWORD="op://prod/account/password"
EOF
op inject)
```