FIND YOUR NEXT FEW LINES

Results for “list files”

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

467 snippets foundClear filters
AngularLists & control flow

Style the first and last list items

Style the first and last list items with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
JavaQueues & collection operations

Take an immutable list snapshot

Java: List.copyOf protects the snapshot from later changes to the source list.

Java✓ Tested
GitInspecting the working tree

Test whether tracked working files changed

Git: A quiet diff returns status one for differences, so handle it in a conditional.

Git✓ Tested
JavaFile operations & binary data

Visit files recursively

Java: Close the stream returned by Files.walk and sort relative paths for stable output.

Java✓ Tested
HTMLGetting Started

Write an unordered list

HTML: Learn how to write an unordered list in a complete browser example.

HTML✓ Tested
RustFiles & paths

Append to a file without truncating it

Append to a file without truncating it in a complete Rust program using the standard library.

Rust✓ Tested
HTMLTables & list numbering

Associate a data cell with explicit table headers

HTML: The headers attribute lists header IDs for a more complex cell association.

HTML✓ Tested
AngularLists & control flow

Bind a narrowed value using an @if alias

Bind a narrowed value using an @if alias with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
C++Filesystem operations

Calculate a lexical relative path

C++: lexically_relative compares path components without requiring the paths to exist.

C++✓ Tested
RustFiles & paths

Change a path’s extension

Change a path’s extension in a complete Rust program using the standard library.

Rust✓ Tested
Linux CommandsFiles & permissions

Copy a directory while preserving attributes

Linux Commands: Use cp -a for a recursive local copy that preserves links and ordinary file attributes.

Linux Commands✓ Tested
RustFiles & paths

Copy a file and inspect the copied byte count

Copy a file and inspect the copied byte count in a complete Rust program using the standard library.

Rust✓ Tested