Results for “Input streams & redirection”
Small, practical examples. Search by task or narrow things down below.
Read a byte prefix
Linux Commands: Use GNU head -c for a fixed number of bytes, independent of line boundaries.
Linux Commands✓ Tested
Read a byte suffix
Linux Commands: Use GNU tail -c to extract a fixed-size ending.
Linux Commands✓ Tested
Require a checkbox to be selected
HTML: A required checkbox is invalid until that individual control is checked.
HTML✓ Tested
Require a nonempty text value
HTML: The required attribute makes an empty text control fail native constraint validation.
HTML✓ Tested
Require numeric values on a chosen step
HTML: The step interval is measured from the minimum value when one is provided.
HTML✓ Tested
Respond while a user types
jQuery: Learn how to respond while a user types in a complete browser example.
jQuery✓ Tested
Select a time in quarter-hour increments
HTML: A time step is expressed in seconds, so 900 represents fifteen minutes.
HTML✓ Tested
Set a file to a specific byte length
Linux Commands: Use truncate to shorten a known scratch file without replacing its inode.
Linux Commands✓ Tested
Split a file into fixed line-count pieces
Linux Commands: Use numeric suffixes for predictable filenames when splitting a large text file.
Linux Commands✓ Tested
Validate a structured text identifier
HTML: The pattern attribute matches the entire nonempty input; required handles the empty case.
HTML✓ Tested
Validate the shape of an absolute URL
HTML: A URL input checks syntax, not whether a resource exists or is safe.
HTML✓ Tested
Abort a conflicting cherry-pick
Git: Abort removes the incomplete replay and returns to the previous branch state.
Git✓ Tested