Results for “Commands & execution context”
Small, practical examples. Search by task or narrow things down below.
Run a one-off container
Run a command and remove its stopped container automatically.
run✓ Tested
Search for text in a file
Find matching lines with their line numbers, ignoring letter case and treating the pattern as literal text.
grep✓ Tested
Show the current directory
Print the absolute path of your current working directory before running commands that depend on relative paths.
directory✓ Tested
Show the first lines of a file
Read only the first three lines of a text file, useful for checking a header or previewing a large log.
head✓ Tested
Show the Linux distribution version
Read the distribution-provided operating system name and version from os-release.
os✓ Tested
Sort and deduplicate lines
Sort lines alphabetically and remove duplicate lines in a predictable C locale.
sort✓ Tested
Validate a complete identifier with a regex
C#: Use absolute anchors and a timeout so the regex checks the complete input with a bounded execution time.
C#✓ Tested