2022-02-14 03:22:51 +01:00
|
|
|
---
|
|
|
|
title: exec
|
|
|
|
layout: command
|
|
|
|
version: 0.59.0
|
|
|
|
---
|
2021-05-30 02:57:04 +02:00
|
|
|
|
2022-02-14 03:22:51 +01:00
|
|
|
Execute a command, replacing the current process.
|
|
|
|
|
|
|
|
## Signature
|
|
|
|
|
|
|
|
```> exec (command) ...rest```
|
2021-05-30 02:57:04 +02:00
|
|
|
|
|
|
|
## Parameters
|
|
|
|
|
2022-02-14 03:22:51 +01:00
|
|
|
- `command`: the command to execute
|
|
|
|
- `...rest`: any additional arguments for the command
|
2021-05-30 02:57:04 +02:00
|
|
|
|
|
|
|
## Examples
|
2022-02-14 03:22:51 +01:00
|
|
|
|
|
|
|
Execute external 'ps aux' tool
|
2021-05-30 02:57:04 +02:00
|
|
|
```shell
|
|
|
|
> exec ps aux
|
2022-02-14 03:22:51 +01:00
|
|
|
```
|
2021-05-30 02:57:04 +02:00
|
|
|
|
2022-02-14 03:22:51 +01:00
|
|
|
Execute 'nautilus'
|
2021-05-30 02:57:04 +02:00
|
|
|
```shell
|
|
|
|
> exec nautilus
|
2022-02-14 03:22:51 +01:00
|
|
|
```
|
2021-05-30 02:57:04 +02:00
|
|
|
|