Skip to content

Instantly share code, notes, and snippets.

@chadfennell
Created February 3, 2026 13:56
Show Gist options
  • Select an option

  • Save chadfennell/46fc687b2c129ac5ac216fef69d9bb27 to your computer and use it in GitHub Desktop.

Select an option

Save chadfennell/46fc687b2c129ac5ac216fef69d9bb27 to your computer and use it in GitHub Desktop.
1Password Hydration
#!/bin/sh
## 1Password CLI: https://developer.1password.com/docs/cli/
## per-env vaults e.g.
# my-proj-local
# my-proj-stage
# my-proj-prod
export OP_ACCOUNT="a-company-name-here.1password.com"
$(op signin);
export SOME_PROJ_DB_URL=$(op read "op://my-proj-local/databases/DB_URL");
USERNAME=$(whoami)
export SOME_PROJ_PER_DEV_WEBHOOK_URL=$(op read "op://my-proj-local/SomePlatform/WEBHOOK_URL_${USERNAME}")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment