Results for “File operations & paths”
Small, practical examples. Search by task or narrow things down below.
Declare LF normalization for a file type
Git: A gitattributes rule records text normalization expectations for matching paths.
Git✓ Tested
Exclude generated files from an archive
Linux Commands: Place exclude options before the input paths to control archive membership.
Linux Commands✓ Tested
Find files by extension
Search a directory tree for regular files with a particular extension and print their paths.
find✓ Tested
List changed files without the full diff
Inspect affected paths before staging.
diff✓ Tested
List files by extension
Enumerate regular files and return their names in order.
Get-ChildItem✓ Tested
List files changed by the current commit
Git: diff-tree exposes the paths changed between a commit and its parent.
Git✓ Tested
List files in a folder
List the names of regular files in a folder in alphabetical order, excluding subdirectories.
directory✓ Tested
List matching files
Enumerate immediate text files and sort their names in C#.
C#✓ Tested
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
List regular files
List immediate regular files in sorted order and close the Java directory stream.
Java✓ Tested
List the paths with unresolved merge conflicts
Git: The U diff filter identifies unmerged entries without parsing human-readable status output.
Git✓ Tested
Measure a small seekable binary file
C: Seek to the end and inspect ftell, checking both operations for errors.
C✓ Tested