Skip to content

A GitHub action that appends a variable to a dotenv file

License

Notifications You must be signed in to change notification settings

stroeer/gh-action-var-to-dotenv

 
 

Repository files navigation

GitHub license

Variable to Dotenv

A GitHub action that appends a variable to a dotenv file.

Usage

steps:
  - uses: TickX/var-to-dotenv@v1.1.1
    with:
      key: 'SOME_API_URI' # [Required]
      value: ${{secrets.SOME_API_URI}} # [Required]
      default: 'https://api.alt.com' # [Optional] if `value` is empty, this is used instead
      nullable: 'false' # [Optional] if the resolved value is empty, the variable will be omitted
      envPath: '.env' # [Optional] The path to the dotenv file (defaults to `.env`)

You can use this more than once in your workflow to add multiple variables.

About

A GitHub action that appends a variable to a dotenv file

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 98.1%
  • JavaScript 1.9%