{"id":23579769,"url":"https://github.com/jacobjove/generate-dotenv","last_synced_at":"2026-02-13T06:18:06.855Z","repository":{"id":58628512,"uuid":"532693509","full_name":"jacobjove/generate-dotenv","owner":"jacobjove","description":"Generates a dotenv file as part of a GitHub Actions workflow.","archived":false,"fork":false,"pushed_at":"2024-06-11T13:52:31.000Z","size":3134,"stargazers_count":2,"open_issues_count":5,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-26T23:12:43.988Z","etag":null,"topics":["dotenv","github-actions"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jacobjove.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2022-09-05T00:32:12.000Z","updated_at":"2023-02-15T23:54:17.000Z","dependencies_parsed_at":"2023-12-21T20:26:47.896Z","dependency_job_id":"8cb8b57b-f417-4499-bbc3-391189683b41","html_url":"https://github.com/jacobjove/generate-dotenv","commit_stats":{"total_commits":80,"total_committers":2,"mean_commits":40.0,"dds":"0.21250000000000002","last_synced_commit":"29c7335cb0633bb194246d3ce454c8d39adcea2c"},"previous_names":["jacobjove/generate-dotenv","iacobfred/generate-dotenv"],"tags_count":39,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacobjove%2Fgenerate-dotenv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacobjove%2Fgenerate-dotenv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacobjove%2Fgenerate-dotenv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacobjove%2Fgenerate-dotenv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jacobjove","download_url":"https://codeload.github.com/jacobjove/generate-dotenv/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239394675,"owners_count":19631117,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["dotenv","github-actions"],"created_at":"2024-12-26T23:12:47.967Z","updated_at":"2025-11-02T10:30:26.317Z","avatar_url":"https://github.com/jacobjove.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Generate dotenv file\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"\"\u003e\u003cimg alt=\"deploy-docker-ssh status\" src=\"https://github.com/iacobfred/generate-dotenv/workflows/units-test/badge.svg\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\nThis action generates a dotenv file (for use in a GitHub Actions workflow) by running `envsubst` on a specified template file (e.g., `_.env`) or multiple template files (e.g., `_.env` and `_.env.production`), which must\nbe included in source control.\n\n## Inputs\n\n### `template-paths`\n\nA space-delimited list of filepaths of the template files that will be used to generate the dotenv file.\n\nThis could be a single filepath (e.g., `'_.env'` or `'.env.template'`) or multiple filepaths\n(e.g., `'_.env _.env.production'`).\n\nIf multiple paths are specified, the templates will be merged (with duplicate variable keys\nremoved, giving priority to the contents of the right-most paths) to produce the final dotenv\nfile. This can be useful for dynamically overriding a base dotenv template depending on the\nenvironment for which the dotenv file is being produced.\n\n### `output-path`\n\n(Optional) The path of the output dotenv file. Default: `'.env'`\n\n### `cache`\n\n(Optional) Boolean specifying whether to cache the dotenv file. Default: `'true'`\n\n### `key`\n\n(Optional) The key used to cache the dotenv file (if caching is not disabled).\n\nIf `key` is not specified, a cache key is computed by concatenating the template paths\nand the `GITHUB_SHA` environment variable.\n\n### `allow-missing-vars`\n\n(Optional) Boolean specifying whether to generate the dotenv file even if one or more variables\nreferenced in the template file is missing from the environment. Default: `'false'`\n\n## Outputs\n\n### `key`\n\nThe key used to cache the dotenv file (if caching is not disabled), or null (if caching is disabled).\n\n## Example usage\n\n### `.github/workflows/[workflow].yml`\n\n```yaml\nname: Generate dotenv file\non: [push]\njobs:\n  generate-dotenv-file:\n    name: Generate dotenv file\n    runs-on: ubuntu-latest\n    env:\n      OMITTED_VAR: asdf\n      SHA: ${{ github.sha }}\n    steps:\n      - uses: actions/checkout@v3\n      - uses: iacobfred/generate-dotenv@v1.0.0\n        with:\n          template-paths: \".config/_.env\"\n          output-path: \".env\"\n        env:\n          SECRET_KEY: ${{ secrets.SECRET_KEY }}\n          VAR_TO_BE_RENAMED: ghjkl\n```\n\n### `.config/_.env`\n\n```sh\nSHA=$SHA\nSECRET_KEY=$SECRET_KEY\nRENAMED_VAR=$VAR_TO_BE_RENAMED\nNONSECRET_IMMUTABLE_VAR=12345\n```\n\n### Output: `.env`\n\n```sh\nSHA=5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f\nSECRET_KEY=Kt4Gn4XRgAMy7EHZPp\nRENAMED_VAR=ghjkl\nNONSECRET_IMMUTABLE_VAR=12345\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacobjove%2Fgenerate-dotenv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjacobjove%2Fgenerate-dotenv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacobjove%2Fgenerate-dotenv/lists"}