FIND YOUR NEXT FEW LINES

Results for “only”

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

621 snippets foundClear filters
PythonFiles & paths

List files in a folder

List the names of regular files in a folder in alphabetical order, excluding subdirectories.

directory✓ Tested
GitInspecting the working tree

List files tracked by Git

Git: ls-files reads the index instead of listing every file in the working directory.

Git✓ Tested
GitInspecting the working tree

List ignored untracked files

Git: Combine ignored with others so the result is specifically ignored working files.

Git✓ Tested
C#Files & paths

List matching files

Enumerate immediate text files and sort their names in C#.

C#✓ Tested
GitMerging & replaying changes

List paths changed on a feature branch since its merge base

Git: A three-dot diff compares the branch tip with the common ancestor.

Git✓ Tested
JavaFiles & paths

List regular files

List immediate regular files in sorted order and close the Java directory stream.

Java✓ Tested
GitTags & repository configuration

List release tags matching a pattern

Git: Use a tag pattern and version-aware sorting for release labels.

Git✓ Tested
GitRemotes & additional checkouts

List remote-tracking branches after a fetch

Git: Remote-tracking references describe the last fetched state rather than live remote state.

Git✓ Tested
GitMerging & replaying changes

List the paths with unresolved merge conflicts

Git: The U diff filter identifies unmerged entries without parsing human-readable status output.

Git✓ Tested
GitInspecting the working tree

List untracked files while honoring ignore rules

Git: Use others and exclude-standard together to respect repository and global ignore configuration.

Git✓ Tested
JavaQueues & collection operations

Locate a value in a sorted array

Java: Use Arrays.binarySearch only after establishing ascending order.

Java✓ Tested
C#Collections

Look up a dictionary value

Use TryGetValue for a C# dictionary lookup with a fallback.

C#✓ Tested