npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

azure-env-generator

v0.1.5

Published

Generate .env files from Azure Variable Groups.

Readme

azure-env-generator

Developer tool for generating .env files from Azure Variable Groups.

Installation

npm install azure-env-generator

Usage

You can run the generator either via the CLI or programatically.

CLI Usage

Before using the CLI command, you must set the environment variable AZURE_ENV_GENERATOR_TOKEN with an Azure Personal Access Token (PAT). This token must have the Variable Groups (read) permission.

Read the Azure documentation for more information on how to create a PAT.

The easiest way to set this variable is to create a .env file in the root of your project:

AZURE_ENV_GENERATOR_TOKEN=personal_access_token

Then to use the generator via the CLI, you can run the following command:

azure-env-generator --organisation my_org --project my_project --group my_variable_group

Note: Variables marked as secrets will be left empty in the generated file. You can set them manually in the .env file and they will be persisted in future runs.

Overrides and additional variables can be specified using the --overrides option.

Example file for specifying overrides, in JSON format:

{
    "VARIABLE_NAME": "override_value",
    "ANOTHER_VARIABLE": "another_value"
}

Then run the following command with a reference to the overrides file:

azure-env-generator --overrides overrides.json -o my_org -p my_project -g my_variable_group

The full list of options are available via the --help option:

azure-env-generator --help

Programmatic Usage

To use the generator programmatically, you can import it and call the generateEnv function:

import { generateEnv } from "azure-env-generator";

await generateEnv({
    azure: {
        token: "personal_access_token",
        organisation: "my_org",
        project: "my_project",
        groupName: "my_variable_group",
    },
    filename: ".env",
    overrides: {
        VARIABLE_NAME: "override_value",
    },
});

Configuration Options

You can configure the generator with the following options:

  • azure.token: Your Azure Personal Access Token (PAT).
  • azure.organisation: The organisation that contains the variable group.
  • azure.project: The project that contains the variable group.
  • azure.groupName: The name of the variable group to fetch.
  • filename: The filename to write the generated environment variables to (default is .env).
  • overrides: An object containing variable overrides or additional variables. If a variable is set to null, it will be fetched from the existing .env file if it exists.

Contributing

Contributions are welcome! Please open an issue or a pull request on GitHub.