Results for “tar”
Small, practical examples. Search by task or narrow things down below.
Count commits unique to each of two branches
Git: The symmetric difference with left-right separates commits reachable from only one side.
Git✓ Tested
Count days between UTC-midnight dates
TypeScript: A day is exactly 86400000 milliseconds for these explicitly UTC-midnight inputs.
TypeScript✓ Tested
Count Unicode code points
Java: Use codePointCount when supplementary characters should count as one rather than two UTF-16 units.
Java✓ Tested
Count Unicode code points in a string
TypeScript: String iteration combines surrogate pairs, unlike the UTF-16 length property.
TypeScript✓ Tested
Count words using a Map
Update a keyed counter without losing its value type.
Map✓ Tested
Create a branch at the original base of a stash
Git: stash branch checks out the stash’s base and reapplies the saved work there.
Git✓ Tested
Create a branch from a known release tag
Git: A named starting revision makes the branch’s initial commit explicit.
Git✓ Tested
Create a lightweight tag at the current commit
Git: A lightweight tag is a direct reference without an annotation object.
Git✓ Tested
Create a network marked for internal connectivity
Docker / Compose: The internal option disables normal external routing for that network.
Docker / Compose✓ Tested
Create a recovery branch for a recently moved commit
Git: The reflog can identify a previous local HEAD position while its entry and objects remain available.
Git✓ Tested
Create a runtime file during the build
Docker / Compose: RUN executes during the build while CMD executes when a container starts.
Docker / Compose✓ Tested
Create a symbolic link
Create a relative symbolic link to a file and inspect its target with readlink.
symlink✓ Tested