env-setup_skill

This skill scans your codebase for environment variables, generates .env.example, validates .env, and ensures .gitignore safety to protect secrets.
  • Python

2.6k

GitHub Stars

2

Bundled Files

2 months ago

Catalog Refreshed

4 months ago

First Indexed

Readme & install

Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.

Installation

Preview and clipboard use veilstrat where the catalogue uses aiagentskills.

npx veilstrat add skill openclaw/skills --skill env-setup

  • _meta.json270 B
  • SKILL.md5.4 KB

Overview

This skill scans a codebase for all referenced environment variables, generates a safe and informative .env.example, validates existing .env files, and checks that secrets are not committed. It classifies variables (secrets, service URLs, config, other), suggests safe defaults and placeholders, and flags missing or unused entries. The skill also verifies .gitignore protection and warns about secrets in git history.

How this skill works

The skill searches common code patterns across languages and config files to discover environment variable names and their reference locations. It extracts and deduplicates variable names, classifies them by pattern (SECRET, URL, CONFIG, OTHER), and builds a grouped .env.example with sensible defaults and secret placeholders. If .env files exist, it compares discovered variables to report missing, unused, and present values; it also verifies .gitignore and inspects git history for accidental commits.

When to use it

  • Preparing a new project for onboarding or open source release.
  • Auditing an existing repo to ensure secrets are not committed.
  • Generating or refreshing .env.example after adding new integrations.
  • Validating multiple environment files (development, production, test).
  • Before merging or publishing to catch missing configuration early.

Best practices

  • Always keep .env out of version control and add standard ignore lines if missing.
  • Use placeholder values for secrets and clear warnings (e.g., change-me-in-production).
  • Group variables by logical sections (app, database, auth, external services).
  • Flag client-exposed vars (e.g., NEXT_PUBLIC_*) distinctly to avoid leaking secrets.
  • Check git history if .env was ever committed and rotate compromised secrets promptly.

Example use cases

  • Scan a mixed-language repo (Python, Node, Go) to generate a consolidated .env.example.
  • Compare discovered variables to an existing .env and produce a validation report of missing and unused keys.
  • Add standard .env ignore entries to .gitignore and warn about leaked files in git history.
  • Validate environment variables referenced in docker-compose and shell scripts, including interpolated defaults.
  • Produce categorized environment docs for onboarding new developers or CI configuration.

FAQ

It targets common patterns in JavaScript/TypeScript, Python, Go, Rust, Docker compose, and general config files (yaml/toml), and includes shell interpolation patterns.

How does it treat secrets versus non-secrets?

It classifies variables by name patterns (KEY, SECRET, TOKEN, PASSWORD) and assigns placeholder values plus a visible SECRET warning in the .env.example.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational
env-setup skill by openclaw/skills | VeilStrat