mirror of
https://github.com/flokoe/bash-hackers-wiki.git
synced 2024-11-25 15:53:41 +01:00
b75c3a588b
find docs/ -depth 3 -name '*.md' | xargs grep '(.*/' -l | \ xargs -I{} \ sed -i '' \ -e 's%(/\([^/#).][^/#).]*\)/\([^/#).][^/#).]*\)\(.md\)\{0\})%(../../\1/\2.md)%g' \ -e 's%(/\([^/#).][^/#).]*\)/\([^/#).][^/#).]*\)#\([a-zA-Z_-][0-9a-zA-Z_-]*\))%(../../\1/\2.md#\3)%g' \ -e 's%(/\([^/#).][^/#).]*\)/\([^/#).][^/#).]*\)/\([^/#).][^/#).]*\)\(.md\)\{0\})%(../../\1/\2/\3.md)%g' \ -e 's%(/\([^/#).][^/#).]*\)/\([^/#).][^/#).]*\)/\([^/#).][^/#).]*\)#\([a-zA-Z_-][0-9a-zA-Z_-]*\))%(../../\1/\2/\3.md#\4)%g' \ -e 's%](\([^:.>)#][^:.>)#]*\))%](../../\1.md)%g' \ -e 's%](\([^:.>)#][^:.>)#]*\)#\([^:.>)#][^:.>)#]*\))%](../../\1.md#\2)%g' \ {} Related to https://github.com/flokoe/bash-hackers-wiki/issues/10
31 lines
963 B
Markdown
31 lines
963 B
Markdown
# Arithmetic evaluation (command)
|
|
|
|
## Synopsis
|
|
|
|
(( <EXPRESSION> ))
|
|
|
|
## Description
|
|
|
|
This command evaluates the [arithmetic expression](../../syntax/arith_expr.md)
|
|
`<EXPRESSION>`.
|
|
|
|
If the expression evaluates to 0 then the exit code of the expression is
|
|
set to 1 (`FALSE`). If the expression evaluates to something else than
|
|
0, then the exit code of the expression is set to 0 (`TRUE`). For this
|
|
return code mapping, please see [this
|
|
section](../../syntax/arith_expr.md#arithmetic_expressions_and_return_codes).
|
|
|
|
The functionality basically is equivalent to what the [`let` builtin
|
|
command](../../commands/builtin/let.md) does. The arithmetic evaluation compound
|
|
command should be preferred.
|
|
|
|
## Examples
|
|
|
|
## Portability considerations
|
|
|
|
## See also
|
|
|
|
- Internal: [arithmetic expressions](../../syntax/arith_expr.md)
|
|
- Internal: [arithmetic expansion](../../syntax/expansion/arith.md)
|
|
- Internal: [The `let` builtin command](../../commands/builtin/let.md)
|