FIND YOUR NEXT FEW LINES

Results for “Split-Path”

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

267 snippets foundClear filters
PowerShellGetting Started

Handle an expected terminating error

PowerShell: Handle an expected terminating error using PowerShell 7.

PowerShell✓ Tested
Bash ScriptsDiagnostics & defensive scripting

Identify whether a name resolves to a builtin

Bash Scripts: type -t reports the command kind without printing a machine-specific path.

Bash Scripts✓ Tested
PowerShellGetting Started

Insert a variable into a string

PowerShell: Insert a variable into a string using PowerShell 7.

PowerShell✓ Tested
PowerShellStrings & literal text

Insert values into a multiline template

PowerShell: A double-quoted here-string expands variable references.

PowerShell✓ Tested
C#Asynchronous work & URI handling

Inspect a parsed URI

C#: Use Uri properties instead of splitting URL strings manually.

C#✓ Tested
Docker / ComposeExecution & file transfer

Inspect changes to a container’s writable layer

Docker / Compose: diff marks added, changed, and deleted filesystem paths.

Docker / Compose✓ Tested
JavaEncoding & structured values

Inspect components of a URI

Java: Use URI parsing instead of splitting a URL at punctuation manually.

Java✓ Tested
JavaScriptRegular expressions & URL encoding

Inspect the parsed pieces of a URL

JavaScript: Use URL properties rather than splitting a URL at punctuation.

JavaScript✓ Tested
TypeScriptRegular expressions & URL encoding

Inspect the parsed pieces of a URL

TypeScript: Use URL properties rather than splitting a URL at punctuation.

TypeScript✓ Tested
PowerShellGetting Started

Join an array into text

PowerShell: Join an array into text using PowerShell 7.

PowerShell✓ Tested
PowerShellStrings & literal text

Join several strings with a separator

PowerShell: The join operator returns one string from an input collection.

PowerShell✓ Tested
PowerShellGetting Started

Keep a dollar sign literal

PowerShell: Keep a dollar sign literal using PowerShell 7.

PowerShell✓ Tested