Description
Common Parameters
Format: declare
Format: typeset
Format: declare-P
Format: typeset-P
Displays the values of all variables.
Format: declare-P VaR
Format: typeset-P VaR
Displays the value of the specified variable VAR.
Format: declare Var = Value
Format: typeset Var = Value
Format: Var = Value
Declare variables and assign values.
Format: declare-I VaR
Format: typeset-I VaR
Define the variable VAR as an integer. After that, you can evaluate the expression directly. The result can only be an integer. If the evaluation fails or is not an integer, set it to 0.
Format: declare-r VaR
Format: typeset-r VaR
Format: readonly VaR
Declare the variable VAR as a read-only variable. Read-Only variables cannot be modified or deleted.
Format: declare-A Var
Format: typeset-A Var
Declare the variable VAR as an array variable. But this is unnecessary. All variables can be used as arrays without explicit definitions. In fact, in a sense, it seems that all the variables are arrays, And the variables assigned with no lower parameters are the same as those assigned to "[0.
Format: declare-F
Format: typeset-F
Display all user-defined functions, including names and function bodies.
Format: declare-F
Format: typeset-F
Display the names of all custom functions.
Format: declare-F func
Format: typeset-F func
Only function definitions of the specified function func are displayed.
Format: declare-x VaR
Format: typeset-x VaR
Format: Export VaR
Set the variable VAR to an environment variable, which can be used in subsequent scripts and programs.
Format: declare-x Var = Value
Format: typeset-x Var = Value
Format: Export Var = Value
Set the variable VAR to an environment variable and assign it to value.