FIND YOUR NEXT FEW LINES

Results for “Files & paths”

Small, practical examples. Search by task or narrow things down below.

495 snippets foundClear filters
Docker / ComposeGetting Started

Choose an image’s default directory

Docker / Compose: Choose an image’s default directory with a complete introductory Dockerfile.

Docker / Compose✓ Tested
Docker / ComposeDockerfile patterns

Choose Bash with pipefail for build commands

Docker / Compose: SHELL changes the interpreter for subsequent shell-form instructions.

Docker / Compose✓ Tested
Docker / ComposeGetting Started

Choose the command a container executes

Docker / Compose: Choose the command a container executes using a locally available Ubuntu image.

Docker / Compose✓ Tested
Docker / ComposeLimits & process security

Choose the signal used for graceful stopping

Docker / Compose: The configured stop signal is recorded in container metadata.

Docker / Compose✓ Tested
PowerShellDates & numeric validation

Clamp a number to inclusive bounds

PowerShell: Math.Clamp chooses the nearest endpoint for an out-of-range value.

PowerShell✓ Tested
Bash ScriptsFiles & reliability

Clean up a temporary directory automatically

Use an EXIT trap so temporary files are removed when the script ends.

mktemp✓ Tested
GitRemotes & additional checkouts

Clone a local bare repository

Git: A local remote provides the same clone workflow without any network dependency.

Git✓ Tested
GitMerging & replaying changes

Combine a branch’s changes into one new commit

Git: Squash prepares the combined changes in the index without recording a merge parent.

Git✓ Tested
Docker / ComposeDockerfile patterns

Combine a stable entrypoint with default arguments

Docker / Compose: CMD supplies default arguments to an exec-form ENTRYPOINT.

Docker / Compose✓ Tested
PowerShellGetting Started

Combine conditions with and

PowerShell: Combine conditions with and using PowerShell 7.

PowerShell✓ Tested
GitCommits & history

Commit a staged change

Save a focused revision with a descriptive message.

commit✓ Tested
PowerShellGetting Started

Compare a value with a limit

PowerShell: Compare a value with a limit using PowerShell 7.

PowerShell✓ Tested