Results for “Split-Path”
Small, practical examples. Search by task or narrow things down below.
Read a UTF-8 file
Read a small UTF-8 file into a Java string.
Java✓ Tested
Read a value from a hashtable
PowerShell: Read a value from a hashtable using PowerShell 7.
PowerShell✓ Tested
Read a value from a trusted XML document
PowerShell: The XML adapter exposes a small document’s elements and attributes through named properties.
PowerShell✓ Tested
Read a whole text file
Load text as one string instead of one item per line.
Get-Content✓ Tested
Read JSON into a hashtable
PowerShell: AsHashtable produces dictionary-style results for keys that are data rather than fixed property names.
PowerShell✓ Tested
Read named fields from a successful regex match
PowerShell: The Matches table is updated after a successful scalar match operation.
PowerShell✓ Tested
Read rows from CSV text
Parse CSV into objects with named properties.
CSV✓ Tested
Read the exact version currently staged
Git: The colon path syntax reads a blob from the index rather than from HEAD or the working file.
Git✓ Tested
Read the kind of command being invoked
PowerShell: CommandType distinguishes cmdlets from functions, aliases, and external applications.
PowerShell✓ Tested
Read the last array element
PowerShell: A negative array index counts backward from the end.
PowerShell✓ Tested
Read the target stored in a symbolic link
Linux Commands: Use readlink without resolving the target path.
Linux Commands✓ Tested
Reject NaN and infinite values
PowerShell: Double.IsFinite excludes numeric values unsuitable for ordinary bounded calculations.
PowerShell✓ Tested