{"id":19501268,"url":"https://github.com/acryps/environment","last_synced_at":"2026-07-29T15:31:17.062Z","repository":{"id":178235349,"uuid":"661561026","full_name":"acryps/environment","owner":"acryps","description":"Environment variable manager for local development","archived":false,"fork":false,"pushed_at":"2025-08-13T09:24:37.000Z","size":58,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-11T09:43:06.810Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/acryps.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-07-03T06:42:33.000Z","updated_at":"2025-08-13T09:24:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"f4d5af9b-e9b8-4da5-ad46-fd44df3b9b57","html_url":"https://github.com/acryps/environment","commit_stats":null,"previous_names":["acryps/environment"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/acryps/environment","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acryps%2Fenvironment","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acryps%2Fenvironment/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acryps%2Fenvironment/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acryps%2Fenvironment/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/acryps","download_url":"https://codeload.github.com/acryps/environment/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acryps%2Fenvironment/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":36038876,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-07-20T02:08:10.276Z","status":"online","status_checked_at":"2026-07-29T02:00:04.910Z","response_time":95,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T22:12:03.878Z","updated_at":"2026-07-29T15:31:17.038Z","avatar_url":"https://github.com/acryps.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# acryps environment\nEnvironment variable manager for local development\n\n## Getting Started\n`npm install @acryps/environment --save-dev`\n\nActive environment by adding `environment` before launching your application in your scripts (will work with any tool)\n\n`tsc \u0026\u0026 node index.js` → `tsc \u0026\u0026 environment node index.js`\n\nDefine environment variables in your `package.json`\n```\n{\n\t\"name\": \"my-application\",\n\t\"environment\": {\n\t\t\"host\": \"Application Host\",\n\t\t\"database\": {\n\t\t\t\"host\": \"Database Host\",\n\t\t\t\"+port?5432\": \"Database Port\"\n\t\t}\n\t}\n}\n```\n\nYou'll automatically be prompted to enter the values required for your project.\nThe following environment variables will automatically be passed as environment variables to the application launched by environment:\n- `HOST`\n- `DATABASE_HOST`\n- `DATABASE_PORT`\n\nAccess them as usual with `process.env.HOST` - no changes to the code required.\nThe variables are stored in `~/.a-environment` and is thus outside of your current git directory - You can store secrets too and they will never end up in your git!\n\n## Switching Settings\nYou may be working on a testing and staging environment. You can quickly switch between different settings in environment, just create a new environment by using\n```\n$ npx environment --switch test\n```\n\nThis will create a new setting 'test', where you can set entirely different environment variables.\nYou'll automatically be prompted to create new variables when you start your application again.\n\n```\n$ npx environment --active-setting # returns the current setting name\n$ npx environment --settings # returns all available settings\n```\n\nYou can switch back to your default setting at any time\n```\n$ npx environment --switch default\n```\n\nYou'll need to restart your program whenever you change variables!\n\n## Editing the values\nJust use `--edit` with an optional prefix (case insensitive).\nYou'll be prompted to enter new values, just press enter to take the current value.\n\n```\n$ npx environment --edit\n$ npx environment --edit database # only database properties\n$ npx environment --edit AUTHENTICATION_ENCRYPTION # only authentication → encryption properties\n```\n\n## Modifiers\nModifiers may be added to the names in the package configuration\n- `…?default`: Set a default value which will be accepted when the user does not provide a value\n- `+…`: Require a numeric value\n\nAdding an uppercase letter in the variables name will automatically be expanded with a `_`: `accessKey` → `ACCESS_KEY`\n\n## Exporting / Importing\nThe current configuration can be exported in various formats for import into other applications.\nYou can send your current configuration to new team members, and they can quickly import them.\n\n```\n$ npx environment --export # exports as environment bundle, for import into environment\n$ npx environment --import \u003cblob\u003e # import the environment bundle into the active setting\n\n$ npx environment --export-json # exports as json\n$ npx environment --export-shell # exports as NAME=\"VALUE\" statements for shell scripts\n$ npx environment --export-dotenv # exports as export NAME=\"VALUE\" statements for .env files\n$ npx environment --export-cluster # exports as vlcluster variable commands\n$ npx environment --export-kubernetes # exports as kubernetes deployment configuration values\n```\n\n# Switching the base path\nYou may switch to use another directories environment by providing `--base \u003cpath\u003e` before any command.\nThe argument must be the first after `environment`.\n\nThis example will use the settings from the server directory.\n```\nenvironment --base ../../server node index.js\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Facryps%2Fenvironment","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Facryps%2Fenvironment","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Facryps%2Fenvironment/lists"}