WeSearch

Every tutorial tells you to add .env to .gitignore. That's not enough.

·2 min read · 0 reactions · 0 comments · 6 views
#security#devtools#opensource
Every tutorial tells you to add .env to .gitignore. That's not enough.
⚡ TL;DR · AI summary

The article discusses the limitations of using .gitignore to protect sensitive information in development projects. It introduces dotlock, a tool designed to encrypt environment variables, ensuring they are not stored in plaintext. The author explains how dotlock works and its benefits for managing local secrets securely.

Key facts
Original article
DEV.to (Top)
Read full at DEV.to (Top) →
Opening excerpt (first ~120 words) tap to expand

try { if(localStorage) { let currentUser = localStorage.getItem('current_user'); if (currentUser) { currentUser = JSON.parse(currentUser); if (currentUser.id === 1150506) { document.getElementById('article-show-container').classList.add('current-user-is-article-author'); } } } } catch (e) { console.error(e); } Muhammad Ahmad Posted on May 30 Every tutorial tells you to add .env to .gitignore. That's not enough. #go #security #opensource #devtools Here's something nobody talks about. .gitignore doesn't encrypt your secrets. It just hides them from git. They're still sitting on your laptop as plaintext. Every tool you install can read them. Every script that runs can read them. One accidental commit and your database password is public on GitHub forever.

Excerpt limited to ~120 words for fair-use compliance. The full article is at DEV.to (Top).

Anonymous · no account needed
Share 𝕏 Facebook Reddit LinkedIn Threads WhatsApp Bluesky Mastodon Email

Discussion

0 comments

More from DEV.to (Top)