Urgent.News

What's breaking now, across thousands of outlets.

Tech

An animated, customizable Git cheat sheet drawn by git-sim

Git is a version control system that tracks changes in files and directories. A repository is a folder containing the project's history stored in a hidden .git directory. To create a new repository or clone an existing one, use the git init command. Settings applied globally using the --global flag affect all repositories on the machine and are saved in the ~/.gitconfig file.

Committing changes consists of two steps: staging the desired changes with git add and then committing them as a single snapshot with git commit. Deleting, renaming, untracking, and ignoring files, as well as clearing Git-tracked files, can be done using various git commands. Every commit retains its author, date, and changes.

Git allows you to view and manipulate commit history using commands like git log, git diff, and git grep. These commands do not alter any data. A branch is a movable pointer to a specific commit, with HEAD referring to the active branch. Merging combines the work from one branch into another while preserving the commit history.

Rebasing replays a branch's commits on top of another branch, providing a linear commit history. A cherry-pick replays individual commits while keeping the commit history intact. Remotes are named URLs for other repositories containing the same project. Cloning creates a new repository with a named remote (origin). Fetching and pulling download new commits from a remote, while pushing sends commits to a remote.

The stash command temporarily saves changes that haven't been committed, allowing you to switch branches and reapply the changes later. Git can undo most mistakes if the correct command is used to reverse the action. Each card in a Git cheat sheet displays the potential impact of the corresponding command.

Written by urgent.news from Lobsters's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at initialcommit.com →

More in Tech

TikTok, Reels and Shorts safe zones in pixels

TikTok puts buttons, captions and your name on top of your video. Text under them is hard to read. The safe zone is the area that stays clear.

  • TikTok requires 240px text distance from top, 660px from bottom, 120px from sides
  • Instagram Reels follows TikTok's 269px/672px/65px safe zone measurements
  • YouTube Shorts allows most generous 288px/672px/48px/192px text placement zone

I built a manga colouriser for a friend, and it runs fully on my laptop

My friend Vinay reads a lot of manga, and it's all black and white. For the Hacktoberfest "Build for a Friend" challenge I built a tool that colours manga pages and keeps each character looking the…

  • Vinay requests manga colorizer for black-and-white pages
  • Application runs locally on laptop without cloud dependencies
  • Uses AI models like Stable Diffusion and OWL-ViT for colorization

From Python Foundations to VISORA BI: Building My First Full-Stack Business Intelligence Platform

A few months ago, I was mostly focused on strengthening my Python fundamentals. Today, I have a working full-stack Business Intelligence platform called VISORA BI , built with Python, Pandas, FastAPI…

  • Python programmer with solid foundation in variables, data types, and functions
  • Developed VISORA BI platform for dataset analysis and AI-powered insights
  • Full-stack architecture with React frontend, FastAPI backend, and Pandas persistence

More from Sunday 4 October →