Unverified50% confidenceFactExact time
The shell redirection operator `>` creates or truncates the target file before the command runs, so when the command fails the output file may still exist but contain empty content or an error message.
1
Sources
50%
Confidence
Long-term
Relevance
10/19/2026
First Seen
Sources
Related Entities
Related Claims
UnverifiedAny guard that inspects command arguments as strings before shell execution can only see the user's original spelling, not the set of files the shell will actually access.72% similarUnverifiedShell glob expansion is completed before command execution, so programs like sed see the expanded real paths rather than the original strings containing wildcards.69% similarUnverifiedA common way to capture a subcommand's error output in a shell script is: use err=$(restic backup ... 2>&1 >/dev/null) to collect stderr into a variable and then check $?; or use set -o pipefail together with tee to both write to disk and forward the output.68% similarUnverifieddisown removes the job from the shell's job table, so when the shell receives SIGHUP it has no job to forward, and the process therefore does not receive SIGHUP.68% similarUnverifiedEnvironment variable assignments (such as $env:FOO=bar or export FOO=bar) are only effective in the current Shell process and its child processes, and become invalid when the terminal is closed; to take effect permanently, they need to be written into the Shell startup script (such as .bashrc, .zshrc, $PROFILE) or system environment variables.67% similar
Cite This Claim
Stable URI
https://kongchang.com/claim/1066843API
curl https://kongchang.com/api/v1/knowledge/claims/1066843MCP
get_claim(id=1066843)