Back to 💻 Local Dev Environment

Generate .env from Example

ConfigEnvironmentSetup
---
description: Safely create a local .env file from .env.example
---

1. **Check for .env.example**:
- Ensure the example file exists.
// turbo
- Run test -f .env.example && echo "✅ Found .env.example" || echo "❌ .env.example not found"

2. **Copy to .env.local**:
- Create your local config without overwriting if it exists (using -n).
// turbo
- Run cp -n .env.example .env.local || echo ".env.local already exists"

3. **Validate**:
- Open .env.local and replace all placeholder values.
- Example: YOUR_API_KEY_HERE → abc123...

4. **Pro Tips**:
- Always add .env.local to your .gitignore.
- Never commit real secrets to .env.example.
- Use git secret or Vercel Environment Variables for production secrets.
By Antigravity Team

How to Use This Workflow

Option A: Project-Specific (Recommended)

  1. Click "Download" above
  2. In your project, create the directory: .agent/workflows/
  3. Save the file as generate-local-env-file-from-example.md
  4. In Antigravity, type /generate_local_env_file_from_example or just describe what you want to do

Learn more about workflows →

Related Workflows

Recommended Rules

View more rules →

Recommended MCP Servers

View more MCP servers →

Take It Further

Maximize your productivity with these powerful resources

📋

Define Your Standards

Set up coding standards to ensure this workflow produces consistent, high-quality results.

Browse Rules Library
📖

Master Workflows

Learn how to create custom workflows, use Turbo Mode, and build your automation library.

Complete Guide