Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
commands:builtin:readonly [2011/01/03 17:33]
thebonsai [Portability considerations]
commands:builtin:readonly [2017/10/17 20:18] (current)
ben_bash [Description]
Line 9: Line 9:
 ===== Description ===== ===== Description =====
  
-The ''​readonly''​ builtin command is used to mark variables or functions as read-only, which means unchangable,​ which implies it can't be unset anymore.+The ''​readonly''​ builtin command is used to mark variables or functions as read-only, which means unchangeable. This implies ​that it can't be unset anymore.  A ''​readonly''​ variable may not be redefined in child scopes. ​ A readonly global may not be redefined as a function local variable. ​ Simple command environment assignments may not reference readonly variables
  
 ==== Options ==== ==== Options ====
Line 22: Line 22:
 ==== Return status ==== ==== Return status ====
  
-The return status is unless an invalid option ​or an invalid combination of options ​is given or a ''​NAME''​ is invalid.+^Status ​ ^Reason ​ ^ 
 +|   |no error  | 
 +|!=0  |invalid option ​ | 
 +|!=0  |invalid combination of options ​ | 
 +|!=0  |given ''​NAME''​ is invalid ​ |
  
 ===== Examples ===== ===== Examples =====
  • commands/builtin/readonly.1294076013.txt
  • Last modified: 2011/01/03 17:33
  • by thebonsai