Skip to content

hisbaan/envman

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

envman

License: GPL v3 Go Version Go Report Card Release

envman is a CLI tool for managing .env files when working with multiple environments, particularly useful in a monorepo. It allows you to hotswap between different environment configurations using symlinks.

Features

  • Manage multiple projects with different environment configurations
  • Define multiple directories within a project for .env file synchronization
  • Quickly switch between environments using symlinks
  • View current project status and active environment

Installation

Go

Ensure you have Go installed (version 1.25.5 or later). Then run:

go install github.com/hisbaan/envman@latest

Build from Source

Clone the repository and build:

git clone https://github.com/hisbaan/envman.git
cd envman
go build -o envman

Usage

Add a Project

Add your current directory or a specific path as a project:

envman proj add [project-dir]

Remove a Project

Remove a project from the configuration:

envman proj rm [project-dir]

Add a Directory

Add a subdirectory to the current project:

envman dir add [dir]

Remove a Directory

Remove a directory from the current project:

envman dir rm [dir]

Link an Environment

Link an environment configuration to .env files across all project directories:

envman link [environment]

Unlink

Remove all .env symlinks:

envman unlink

Status

View the current project status, directories, and active environment:

envman status

Configuration

envman stores its configuration in ~/.config/envman/config.toml. The configuration is managed automatically through the CLI commands.

About

A quick Go CLI for managing .env files in my projects

Resources

License

Stars

Watchers

Forks

Sponsor this project

 

Packages

 
 
 

Contributors

Languages