FIND YOUR NEXT FEW LINES

Results for “Set-Content”

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

604 snippets foundClear filters
Bash ScriptsArray operations

Read an optional associative-array entry

Bash Scripts: Use a fallback expansion when a map key may not be present under nounset.

Bash Scripts✓ Tested
GitCommit history & revision selection

Read commit subjects affecting one file

Git: Place the path after -- so Git limits history to the selected file.

Git✓ Tested
GitCommit history & revision selection

Read commit subjects from oldest to newest

Git: Reverse the normal newest-first history order.

Git✓ Tested
GitGetting Started

Read history for one path

Git: Read history for one path inside the disposable repository created by the input setup.

Git✓ Tested
Docker / ComposeContainer commands

Read output from a completed container

Retrieve the stdout captured by Docker.

logs✓ Tested
GitCommits & history

Read recent commit messages

View a compact history in newest-first order.

log✓ Tested
GitGetting Started

Read repository-local configuration

Git: Read repository-local configuration inside the disposable repository created by the input setup.

Git✓ Tested
GitStashing selected work

Read stash labels without commit hashes

Git: A custom format provides predictable stash subjects.

Git✓ Tested
C++Filesystem operations

Read the byte size of a regular file

C++: file_size reads filesystem metadata without loading file contents.

C++✓ Tested
GitBranches & ancestry

Read the current branch name

Git: show-current returns an empty string when HEAD is detached.

Git✓ Tested
GitGetting Started

Read the latest commit message

Git: Read the latest commit message inside the disposable repository created by the input setup.

Git✓ Tested
GitRemotes & additional checkouts

Read the upstream tracked by the current branch

Git: The upstream shorthand resolves the configured remote-tracking branch.

Git✓ Tested