2018-12-01 17:55:20 +00:00
|
|
|
# unset
|
|
|
|
|
|
|
|
> Remove shell variables or functions.
|
2021-07-11 18:17:29 +01:00
|
|
|
> More information: <https://manned.org/unset>.
|
2018-12-01 17:55:20 +00:00
|
|
|
|
2020-07-05 21:50:40 +01:00
|
|
|
- Remove the variable `foo`, or if the variable doesn't exist, remove the function `foo`:
|
|
|
|
|
|
|
|
`unset {{foo}}`
|
|
|
|
|
2018-12-01 17:55:20 +00:00
|
|
|
- Remove the variables foo and bar:
|
|
|
|
|
2020-07-05 21:50:40 +01:00
|
|
|
`unset -v {{foo}} {{bar}}`
|
2018-12-01 17:55:20 +00:00
|
|
|
|
|
|
|
- Remove the function my_func:
|
|
|
|
|
|
|
|
`unset -f {{my_func}}`
|