Ultimate Cheatsheet for Developers

Curated list of useful resources and cheatsheets for web developers

View the Project on GitHub zlatanstajic/ultimate-cheatsheet-for-developers

Ultimate Cheatsheet for Developers

CI License: MIT Node: >=20 freshness

Making everyday development easier.

A curated collection of developer cheatsheets and resource lists written in plain Markdown. The same content is published as a Jekyll site on GitHub Pages, searched in the browser through a prebuilt index, read from the terminal through the ucheat CLI, and exported offline as print-ready HTML or a VS Code snippet bundle.

Ultimate Cheatsheet for Developers social preview

Table of Contents


Features

⬆ back to top


Tech Stack

⬆ back to top


Cheatsheets

Knowledgebase

Name Description
GitHub Repos Curated list of useful GitHub repositories for web development.
Learning Sources Useful learning sources and documentation for web development.
Web Development Tools Handy tools and utilities for web developers.
Books To Read Recommended books for software developers.
Linux Apps Recommended Linux applications for developers.

Shell

Name Description
Composer Dependency management for PHP projects.
cURL Command-line tool for transferring data with URLs.
Git Version control system for tracking code changes.
Git Crypt Transparent file encryption for version control.
Linux Useful Linux commands and tips.
MySQL Commands for MySQL database management.
PostgreSQL PostgreSQL relational database management.
Node Node.js runtime and command-line usage.
npm Node.js package manager commands.
Python Python programming language and package management.
Docker Container platform for building and running applications.
Redis In-memory data structure store for caching and data management.
PHP PHP command-line usage and scripting.
SSH Secure remote login and command execution.
jq Command-line JSON processor.
tmux Terminal multiplexer for sessions, windows, and panes.
systemctl Control the systemd system and service manager.

Each folder also has its own index page: knowledgebase/README.md and shell/README.md. When a page is added or renamed, both this table and the folder index need the new link.

⬆ back to top


Install

Reading the cheatsheets needs nothing installed — open any Markdown file on GitHub or browse the published site. The steps below set up the validation and export tooling for contributors.

Requirements

Local Setup

Clone the repository and install the tooling:

git clone https://github.com/zlatanstajic/ultimate-cheatsheet-for-developers.git
cd ultimate-cheatsheet-for-developers
npm install

npm install runs the prepare script, which installs the Husky pre-commit hook. Verify the setup with:

npm test

There is no application to start and no environment file to create.

⬆ back to top


Usage

Website

The site is published from master to https://zlatanstajic.github.io/ultimate-cheatsheet-for-developers by GitHub Pages, using the settings in _config.yml. Jekyll renders every Markdown page with the theme’s default layout and excludes bin/, scripts/, and the CLI index from the site.

search.html queries a prebuilt lunr index and links each result to the matching page and section anchor. The index lives in assets/search-index.json and is regenerated by the pre-commit hook; to rebuild it by hand, run:

npm run build:index

CLI

bin/ucheat.mjs renders cheatsheet sections in the terminal. From a clone:

# Show usage and the list of available tools
node bin/ucheat.mjs --help

# List the sections of a tool's cheatsheet
node bin/ucheat.mjs docker

# Render a section (fuzzy-matched, so "git stsh" works too)
node bin/ucheat.mjs git stash

The same entry point is packaged for npm as ucheat, but the package is not published yet — run it as node bin/ucheat.mjs from a clone. Once a first release lands it will also be callable as npx ucheat git stash. It exits 0 when a section was rendered, 1 when nothing matched, and 2 when the query was ambiguous, in which case it prints the closest candidates instead of guessing.

The CLI reads the prebuilt index at assets/cli-index.json and never parses Markdown at runtime. Editing anything under shell/, knowledgebase/, or this README changes that index:

npm run build:cli-index

Commit the regenerated assets/cli-index.json alongside the content change — npm test fails on any drift. The same applies to assets/search-index.json: the pre-commit hook rebuilds and stages it for you, and npm test fails if a committed index is stale.

Exports

To take the cheatsheets offline, generate the export artifacts locally:

npm run build:print     # print-optimized HTML pages in dist/print/
npm run build:snippets  # VS Code snippet bundle in dist/snippets/cheatsheets.code-snippets
npm run build:export    # both of the above

Output lands in the git-ignored dist/ folder. Open any page from dist/print/ in a browser and print to PDF for a paper copy, one card per section. Place cheatsheets.code-snippets in your VS Code snippets folder to get the shell commands as editor snippets.

The snippet builder has a self-test that asserts against real cheatsheet content and writes nothing. It runs as part of npm test, and again before a release build:

node scripts/build-snippets.mjs --check

⬆ back to top


Content Metadata

Every page under shell/ and knowledgebase/ opens with a YAML frontmatter block:

---
last_reviewed: 2026-03-27
tested_on: git 2.43
---
Key Required Description
last_reviewed Yes ISO date (YYYY-MM-DD) on which the page content was last verified. A manual attestation; nothing derives it from git.
tested_on No Tool version the commands were verified against. A string, or a YAML list when several versions were checked.

Two report-only scripts read this metadata. Both always exit zero and neither is part of npm test or the pre-commit hook:

npm run check:freshness  # writes assets/freshness-badge.json, the badge above
npm run check:drift      # lists pages edited after their attested review date

The freshness badge counts pages whose last_reviewed is older than 183 days, plus pages with a missing or invalid date. The two folder index pages are excluded from the count. Full details are in CONTRIBUTING.md.

⬆ back to top


Testing

Run the complete validation suite:

npm test

That runs six gates in order: lint:md, check:links, spell, check:snippets, check:cli-index, check:index.

Both index checks rebuild their artifact and compare it with HEAD. After a content edit, regenerate both indexes with npm run build:cli-index and npm run build:index; the index gates still report a diff until the content and generated artifacts are committed together. This is expected for uncommitted changes, even when generation succeeds. Because the CLI check runs first, its failure prevents the search-index check from running in that invocation.

check:links validates relative links and in-page anchors only, so the gate makes no network calls and cannot fail because a third-party site is down. External URLs are checked by npm run check:links:external, which runs weekly rather than on every push.

The lint, link, and spell scripts enumerate tracked Markdown with git ls-files, so a brand-new page is not checked until it has been git added once. There is no single-file runner; to check one file, call the tool directly:

npx remark --quiet --frail shell/git.md
npx cspell shell/git.md
npx markdown-link-check --config .mlc-config.json shell/git.md
npx markdown-link-check --config .mlc-config.external.json shell/git.md  # external URLs too

New command flags, tool names, and proper nouns will fail the spell check. Add them to the words array in .cspell.json rather than rewording the content.

⬆ back to top


Continuous Integration

Four GitHub Actions workflows run against this repository:

Workflow Trigger What it does
ci.yml Push and pull requests to master Runs the gate on Node 22.22.1 and the current LTS, plus a CLI smoke test on Node 20
check-links.yml Mondays 07:00 UTC, manual Checks external URLs in every tracked page; reports rot, gates nothing
check-freshness.yml Content pushes, Mondays 06:00 UTC, manual Rebuilds the freshness badge JSON and commits any change
release-export.yml Manual, takes an existing tag input Checks out that tag, builds both exports, and attaches them to its GitHub Release

check-freshness.yml pushes to master as github-actions[bot] with [skip ci], only when the generated file actually changed, and holds a serialized concurrency group that any further master-pushing workflow must join.

Pre-commit Hook

The repository includes a Husky hook at .husky/pre-commit. It runs lint-staged, applying the lint, spell, and link checks to staged *.md files, then rebuilds the search index and stages assets/search-index.json if it changed. The hook is installed by npm’s prepare script when dependencies are installed. To install or refresh it explicitly, run:

npm run prepare

A failing check aborts the commit. Run npm test directly to reproduce the failure. Bypass the hook for a single commit only when necessary with:

git commit --no-verify

⬆ back to top


Open Graph Image

The social preview at assets/img/og-image.png is generated, not hand-drawn. Regenerate it after changing the project name or tagline:

python3 scripts/gen-og-image.py

The script requires Pillow and a bold DejaVu or Liberation TrueType font. It contains no randomness and no timestamps, so the same inputs produce a byte-identical PNG on every run; if no suitable font is installed it fails loudly rather than falling back to a low-resolution default.

⬆ back to top


Contributing

Contributions are welcome. See CONTRIBUTING.md for how to propose a change, add a page, and keep the frontmatter and generated artifacts in sync.

⬆ back to top


Code of Conduct

See CODE_OF_CONDUCT.md for participation guidelines and how to report conduct concerns.

⬆ back to top


Security

Found a credential in the repository, an undocumented destructive command, or a hijacked link? Report it privately by email rather than in a public issue — see SECURITY.md for what qualifies and how to send it.

⬆ back to top


License

This project is licensed under the MIT License. See the LICENSE file for details.

⬆ back to top