envchain
brew install envchain
v1.1.0
MIT
Secure your credentials in environment variables
45
30-day installs · #4923
106
90-day · #5469
428
365-day · #5476
1.3k
★ GitHub stars · updated 2y ago
GitHub topics
credentials
gnome-keyring
keychain
secret
security
Links
- https://github.com/sorah/envchain
- GitHub: sorah/envchain
- Brew formula source: Formula/e/envchain.rb
Raw metadata
{
"aliases": [],
"alternatives": [],
"build_dependencies": [],
"categories": [],
"caveats": null,
"conflicts_with": [],
"dependencies": [],
"deprecated": 0,
"deprecation_reason": null,
"desc": "Secure your credentials in environment variables",
"disable_reason": null,
"disabled": 0,
"enrichment_fetched_at": "2026-06-20T23:37:20+00:00",
"first_seen": "2026-06-20T23:34:18+00:00",
"full_name": "envchain",
"github_default_branch": "master",
"github_last_commit_at": "2024-04-23T18:12:12Z",
"github_readme_excerpt": "# envchain - set environment variables with macOS keychain or D-Bus secret service\n\n## What?\n\nSecrets for common computing environments, such as `AWS_SECRET_ACCESS_KEY`, are\nset with environment variables.\n\nA common practice is to set them in shell\u0027s intialization files such as `.bashrc` and `.zshrc`.\n\nPutting these secrets on disk in this way is a grave risk.\n\n`envchain` allows you to secure credential environment variables to your secure vault, and set to environment variables only when you called explicitly.\n\nCurrently, `envchain` supports macOS keychain and D-Bus secret service (gnome-keyring) as a vault.\n\nDon\u0027t give any credentials implicitly!\n\n## Requirement (macOS)\n\n- macOS\n - Confirmed to work on OS X 10.11 (El Capitan), macOS 10.12 (Sierra).\n - OS X 10.7 (Lion) or later is required, but not confirmed\n\n## Requirement (Linux)\n\n- readline\n- libsecret\n- D-Bus Secret Service\n - GNOME keyring\n - KeePassXC\n\n## Installation\n\n### From Source\n\n```\n$ make\n\n$ sudo make install\n(or)\n$ cp ./envchain ~/bin/\n```\n\n### Homebrew (OS X)\n\n```\nbrew install envchain\n```\n\n## Usage\n\n### Saving variables\n\nEnvironment variables are set within a specified _namespace._ You can set variables in a single command:\n\n```\nenvchain --set NAMESPACE ENV [ENV ..]\n```\n\nYou will be prompted to enter the values for each variable.\nFor example, we can set two variables... `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` here, within a namespace called `aws`:\n\n```\n$ envchain --set aws AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY\naws.AWS_ACCESS_KEY_ID: my-access-key\naws.AWS_SECRET_ACCESS_KEY: secret\n```\n\nHere we define a single new variable within a different namespace:\n\n```\n$ envchain --set hubot HUBOT_HIPCHAT_PASSWORD\nhubot.HUBOT_HIPCHAT_PASSWORD: xxxx\n```\n\nThese will all appear as application passwords with `envchain-NAMESPACE` in the data store (Keychain in macOS, gnome-keyring in common Linux distros).\n\n### Execute commands with defined variables\n\n```\n$ env | grep AWS_ || echo \"No AWS_ env vars\"",
"github_repo": "sorah/envchain",
"github_stars": 1311,
"github_topics": [
"credentials",
"gnome-keyring",
"keychain",
"secret",
"security"
],
"homepage": "https://github.com/sorah/envchain",
"homepage_og_description": null,
"homepage_og_image": null,
"homepage_title": null,
"installs_30d": 45,
"installs_365d": 428,
"installs_90d": 106,
"keg_only": 0,
"keg_only_reason": null,
"last_seen": "2026-06-20T23:34:18+00:00",
"license": "MIT",
"llm_generated_at": null,
"llm_model": null,
"name": "envchain",
"oldnames": [],
"one_liner": null,
"optional_dependencies": [],
"rank_30d": 4923,
"rank_365d": 5476,
"rank_90d": 5469,
"raw_hash": "ac19dc7a22b96786",
"recommended_dependencies": [],
"revision": 0,
"ruby_source_path": "Formula/e/envchain.rb",
"tap": "homebrew/core",
"test_dependencies": [],
"uses_from_macos": [],
"version_head": "HEAD",
"version_stable": "1.1.0",
"versioned_formulae": [],
"why_use_this": null
}