Results for “os”
Small, practical examples. Search by task or narrow things down below.
Check that an image has layer history
Docker / Compose: history shows the instructions associated with image layers.
Docker / Compose✓ Tested
Check whether a function has been defined
Bash Scripts: declare -F tests a function name without executing it.
Bash Scripts✓ Tested
Check whether a variable exists under nounset
Bash Scripts: The plus expansion distinguishes an unset variable without reading its missing value.
Bash Scripts✓ Tested
Clone inert template content into the document
HTML: Template children stay out of the rendered document until their fragment is inserted.
HTML✓ Tested
Combine a stable entrypoint with default arguments
Docker / Compose: CMD supplies default arguments to an exec-form ENTRYPOINT.
Docker / Compose✓ Tested
Combine results while retaining duplicates
Postgres: UNION ALL does not spend work removing equal rows.
Postgres✓ Tested
Combine text values with a separator
Postgres: Use the concatenation operator supported by the selected SQL dialect.
Postgres✓ Tested
Commit multiple related changes together
Postgres: The first transaction prepares the fixtures. The second commits both updates as one unit.
Postgres✓ Tested
Compare a row with its own group average
Postgres: A correlated aggregate computes a different comparison value for each group.
Postgres✓ Tested
Compare floating-point calculations with tolerance
Python: Use isclose instead of exact equality for results affected by floating-point rounding.
Python✓ Tested
Compute an integer weighted average
Postgres: Multiply before summing and guard a zero total weight with NULLIF.
Postgres✓ Tested
Configure bounded retries after a failure
Docker / Compose: on-failure with a count limits automatic restart attempts.
Docker / Compose✓ Tested