.env.example generator prompt for any project

Paste your code and get a documented .env.example file listing every environment variable it uses, safe to commit.

بواسطة ‪Ahmed Eid‬‏0 نسخة

متى تستخدم هذا البرومبت

  • When onboarding a new developer who needs to know which env vars to set.
  • When a project has grown env vars organically with no central list.
  • When preparing a repo for open-sourcing.

نص البرومبت

Generate a .env.example file for a {{language}} project using {{framework}}, based on the environment variables referenced in this code. Add a one-line comment explaining each variable.

{{CLIPBOARD}}
{{language}}{{framework}}{{CLIPBOARD}}

الكتلة {{CLIPBOARD}} تُستبدل تلقائياً بما نسخته قبل الضغط على «نسخ».

كيف تستخدمه

  1. انسخ البرومبت بالزر أو املأ المتغيرات أولاً.
  2. الصقه في ChatGPT أو Claude أو Gemini.
  3. عدّل النتيجة أو أعد الطلب بتغيير المتغيرات.

مثال على النتيجة

# Database connection string, e.g. postgres://user:pass@localhost:5432/db
DATABASE_URL=

# Secret used to sign JWTs, generate with openssl rand -hex 32
JWT_SECRET=

# Optional: set to debug for verbose logging, defaults to info
LOG_LEVEL=info

نصائح للاستخدام

  • Paste multiple files if env vars are read in several places, so none are missed.
  • Never include real secret values, only variable names and safe example/placeholder formats.
  • Ask it to group variables by category (database, auth, third-party APIs) if the list is long.

أسئلة شائعة

Will it accidentally include real secret values from my code?
No, it only lists variable names with placeholder or example values; double-check before committing regardless.
Can it find env vars used indirectly, like in a config loader?
Paste the config loader file too; it can only detect variables visible in the code you provide.

برومبتات ذات صلة

Generate a GraphQL Schema from a Description

Describe your data and operations in plain English and get a complete, documented GraphQL schema.

Design a GraphQL schema (types, queries, mutations) for: {{focus}}. Use {{language}} conventions and include field-level descriptions. {{CLIPBOARD}}

{{focus}}{{language}}{{CLIPBOARD}}

Generate Realistic Mock Data for Testing

Get realistic, varied mock data, including edge cases, matched to your schema, ready to seed a test database.

Generate {{focus}} realistic mock/test data records in {{language}} format for this schema or type, with varied and edge-case values. {{CLIPBOARD}}

{{focus}}{{language}}{{CLIPBOARD}}

Explain What This Legacy Code Actually Does

Paste unfamiliar or legacy code and get a plain-language walkthrough, with dead code and possible bugs flagged.

Walk through this {{language}} code line by line and explain what it does, in plain language. Flag anything that looks like dead code, a workaround, or a potential bug. {{CLIPBOARD}}

{{language}}{{CLIPBOARD}}

Generate a Dockerfile for Your App

Get a secure, optimized Dockerfile tailored to your language and framework, ready to build and run.

Write a production-ready Dockerfile for a {{language}} app using {{framework}}. Use multi-stage builds where useful, minimize image size, and run as a non-root user. Notes: {{focus}}. {{CLIPBOARD}}

{{language}}{{framework}}{{focus}}{{CLIPBOARD}}
المزيد في برمجة