https://github.com/abdosorour7/dev-commands-cheatsheet
The ultimate offline-ready Developer Cheatsheets for Git, Docker, and more: searchable, copy-ready, and organized for real-world workflows.
https://github.com/abdosorour7/dev-commands-cheatsheet
cheatsheet command-line-tool developer-tools docker git
Last synced: 29 days ago
JSON representation
The ultimate offline-ready Developer Cheatsheets for Git, Docker, and more: searchable, copy-ready, and organized for real-world workflows.
- Host: GitHub
- URL: https://github.com/abdosorour7/dev-commands-cheatsheet
- Owner: abdosorour7
- Created: 2026-04-29T22:19:23.000Z (2 months ago)
- Default Branch: main
- Last Pushed: 2026-05-24T22:52:46.000Z (about 2 months ago)
- Last Synced: 2026-05-25T00:31:14.371Z (about 2 months ago)
- Topics: cheatsheet, command-line-tool, developer-tools, docker, git
- Language: JavaScript
- Homepage: https://abdosorour7.github.io/dev-commands-cheatsheet/
- Size: 998 KB
- Stars: 177
- Watchers: 2
- Forks: 24
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ๐ง Dev Cheatsheets
### A fast, searchable, professional reference for everyday developer commands
[](https://abdosorour7.github.io/dev-commands-cheatsheet) [](https://github.com/abdosorour7/dev-commands-cheatsheet/issues)
**Sections:** Git ยท Docker โ and growing
**Data-driven ยท Fast search ยท Copy-ready ยท Multilingual**

---
## ๐ Why This Repo
- Built for speed: open, search, copy, and move on
- Covers real daily workflows for the tools developers use most
- Easy to extend with **new sections** (Git, Docker, โฆ) without touching the rendering code
- Designed to be contributor-friendly
- Clean UI that is readable for long sessions
---
## โจ Features
- ๐๏ธ **Multiple sections** โ switch between **Git** and **Docker** cheatsheets with a single click; new sections drop in via a JSON manifest
- โจ **Multilingual** โ switch between English ๐ฌ๐ง, Italian ๐ฎ๐น, French ๐ซ๐ท, and Spanish ๐ช๐ธ; your choice is remembered across visits
- ๐ **Instant search** โ filter any command or description in real time, scoped to the active section
- ๐ **One-click copy** โ click any command to copy it to your clipboard
- โ ๏ธ **Danger warnings** โ destructive commands are clearly marked
- โจ๏ธ **Keyboard shortcut** โ press `/` to focus search instantly
- ๐ฑ **Fully responsive** โ works great on mobile and desktop
- ๐ **Dark terminal theme** โ easy on the eyes, built for developers
- ๐ก **PWA / offline** โ installable, with service worker caching
- ๐งฉ **Modular architecture** โ separate data, rendering, state, and interactions
---
## ๐๏ธ Architecture
This project uses a clean static architecture with no framework and no build requirement.
- **`index.html`**: page shell, section pills, semantic structure
- **`assets/css/styles.css`**: visual design, layout, responsive styles
- **`assets/data/sections.json`**: manifest for each section (`key`, `title`, `logo`, `#RRGGBB` `color`, docs URL, `docsLabelKey`)
- **`assets/brands/`**: SVG marks for the section switcher (see `README.md` in that folder for attribution)
- **`assets/data/{section}.{lang}.json`**: per-section command data (e.g. `git.en.json`, `docker.en.json`)
- **`assets/data/ui.json`**: all UI strings keyed by locale (`en`, `it`, `fr`, `es`)
- **`assets/js/app.js`**: app bootstrap and orchestration (sections + language)
- **`assets/js/modules/`**:
- `paths.js` โ resolves `assets/data/โฆ`, `assets/brands/โฆ`, and other static URLs from the current page (GitHub Pagesโfriendly)
- `data-loader.js` โ loads `sections.json` and section data on demand (per language, with English fallback per command)
- `render.js` โ renders section pills, category tabs, and command cards
- `state.js` โ section, category, and search filtering state
- `interactions.js` โ copy, keyboard, scroll behavior
- `i18n.js` โ language switching, UI strings, and `localStorage` persistence (lang + section)
Scripts are loaded as **classic** `` files (not ES modules) so the app runs even when a simple local server serves `.js` as `text/plain` (common with `python -m http.server` on Windows). Strict MIME checks for `type="module"` do not apply.
This keeps the app easy to maintain, easy to extend, and contributor-friendly.
### โ Adding a new section (e.g. Linux, Kubernetes)
1. Add an entry in `assets/data/sections.json` (each section needs a stable `key`, human `title`, `logo` path under `assets/brands/` or `assets/`, theme `color` as `#RRGGBB`, docs link, and `docsLabelKey` matching a key in `ui.json`):
```json
{
"key": "kubernetes",
"title": "Kubernetes",
"logo": "assets/brands/kubernetes.svg",
"color": "#326CE5",
"docsUrl": "https://kubernetes.io/docs/reference/kubectl/",
"docsLabelKey": "footerDocs"
}
```
2. Add the logo SVG under `assets/brands/` (square viewBox, ~24px artwork scales cleanly in the section pills).
3. Create `assets/data/kubernetes.en.json` using the same shape as `git.en.json` / `docker.en.json` (top-level `categories`, each with `commands`).
4. Optional: add localized variants like `kubernetes.fr.json`. Missing translations fall back to English at runtime with an `EN` badge.
5. Add new static files to `sw.js`'s `ASSETS` array and bump `CACHE_NAME` so they work offline after deploy.
No JavaScript changes are required for a new section beyond listing new files in the service worker.
### โ Adding a new command
1. Add the command to the appropriate `assets/data/{section}.en.json` (required, source of truth).
2. Optionally add translated entries in the other `{section}.{lang}.json` files in the same PR.
3. The UI shows an **EN** badge when a command is shown in English for the active language: missing locale file (all commands), missing row in a locale file, or when `descriptionHtml` still matches the English text after merge (so leaving English copy in a translated file is detected automatically).
### ๐ Adding a new language
1. Add the locale's UI strings to `assets/data/ui.json`.
2. Add a button to the `#lang-switcher` in `index.html` and to the `SUPPORTED_LANGS` array in `assets/js/modules/i18n.js`.
3. Translate the per-section files you want to support (`git.{lang}.json`, `docker.{lang}.json`, โฆ). Files can be partial โ any missing commands fall back to English at runtime.
**EN badge (automatic):** `assets/js/modules/data-loader.js` merges each section with English, then marks cards with `_fallback: "en"` when there is no `{section}.{lang}.json`, when a command row is absent in that file, or when `descriptionHtml` equals the English entry (normalized whitespace). The card renderer reads `_fallback` and shows the localized โnot translatedโ hint from `ui.json`.
---
## ๐ Sections
| Section | Categories | Commands |
|---------|-----------:|---------:|
| ๐ฑ Git | 13 | 127 |
| ๐ณ Docker | 11 | 142 |
### Git categories
โ๏ธ Setup & Config ยท ๐ Starting a Repo ยท ๐ Basic Workflow ยท ๐ฟ Branching ยท โ๏ธ Remote (GitHub) ยท โฉ๏ธ Undo & Fix ยท ๐ฆ Stash ยท ๐ท๏ธ Tags ยท ๐ Signing & Verification ยท ๐ History & Diff ยท ๐งน Cleanup & Maintenance ยท ๐ฒ Worktrees ยท ๐ Advanced Branching
### Docker categories
โ๏ธ Setup & Info ยท ๐ณ Images ยท ๐ Run Containers ยท ๐ Container Lifecycle ยท ๐ Inspect & Logs ยท ๐พ Volumes ยท ๐ Networks ยท ๐ Docker Compose ยท ๐ Dockerfile Instructions ยท ๐ท๏ธ Registry & Sharing ยท ๐งน Cleanup & Maintenance
---
## ๐ Quick Start
### Option 1 โ Use the live website
Just visit: **[abdosorour7.github.io/dev-commands-cheatsheet](https://abdosorour7.github.io/dev-commands-cheatsheet)**
### Option 2 โ Run locally
```bash
git clone https://github.com/abdosorour7/dev-commands-cheatsheet.git
cd dev-commands-cheatsheet
```
Open `index.html` first (double-click it, or open it in your browser).
If the page works, you are done.
If commands do not load (browser blocks `file://` JSON loading), run a local server:
```bash
python -m http.server 8080
```
Then open: **http://localhost:8080**
If Python is not installed, use one of these alternatives:
```bash
# Option A (Node.js)
npx serve .
# Option B (VS Code extension)
Use "Live Server" and open the project root
```
No build tools required for local development.
---
## ๐งฑ Project Structure
```text
dev-commands-cheatsheet/
โโ index.html
โโ manifest.json
โโ sw.js
โโ assets/
โ โโ brands/
โ โ โโ README.md
โ โ โโ git.svg
โ โ โโ docker.svg
โ โโ css/
โ โ โโ styles.css
โ โโ data/
โ โ โโ sections.json โ list of sections (Git, Docker, โฆ)
โ โ โโ git.en.json โ Git โ English (canonical source)
โ โ โโ git.it.json โ Git โ Italian
โ โ โโ git.fr.json โ Git โ French
โ โ โโ git.es.json โ Git โ Spanish
โ โ โโ docker.en.json โ Docker โ English (canonical source)
โ โ โโ ui.json โ UI strings for all locales
โ โโ js/
โ โโ README.md
โ โโ app.js
โ โโ modules/
โ โโ paths.js
โ โโ data-loader.js
โ โโ i18n.js
โ โโ interactions.js
โ โโ render.js
โ โโ state.js
โโ README.md
```
---
## ๐ Support This Project
- โญ Star the repository if it helped you
- ๐ด Fork it and customize your own version
- ๐ฃ Share it with teammates or in dev communities
- ๐ Open issues for mistakes or missing commands
---
## ๐ค Contributing
Contributions are warmly welcome and highly appreciated.
- โ Add useful missing commands to existing sections
- ๐ Propose entirely new sections (Linux, Kubernetes, npm, AWS CLI, โฆ)
- ๐ Improve command descriptions and examples
- ๐ Add or improve translations
- ๐จ Suggest UI/UX improvements
Open an issue or PR directly and include clear details/screenshots when relevant.
---
## ๐ License
MIT ยฉ [abdosorour7](https://github.com/abdosorour7) โ free to use, share, and modify.
---
<div align="center">
If this helped you, please consider giving it a โญ โ it helps others discover it!
***I'm not primarily a web developer โ I just build practical tools that solve real problems.***
Built with thoughtful AI assistance.
---
**Made with โค๏ธ for the developer community**
</div>