Samuel Dionne-Riel | e69e1f1 | 2022-08-18 15:44:04 -0400 | [diff] [blame] | 1 | .. SPDX-License-Identifier: GPL-2.0-or-later: |
| 2 | |
Heinrich Schuchardt | 1b0c316 | 2024-01-14 14:53:13 +0100 | [diff] [blame] | 3 | .. index:: |
| 4 | single: pause (command) |
| 5 | |
Samuel Dionne-Riel | e69e1f1 | 2022-08-18 15:44:04 -0400 | [diff] [blame] | 6 | pause command |
| 7 | ============= |
| 8 | |
| 9 | Synopsis |
| 10 | -------- |
| 11 | |
| 12 | :: |
| 13 | |
| 14 | pause [prompt] |
| 15 | |
| 16 | |
| 17 | Description |
| 18 | ----------- |
| 19 | |
| 20 | The pause command delays execution waiting for any user input. |
| 21 | |
| 22 | It can accept a single parameter to change the prompt message. |
| 23 | |
| 24 | Examples |
| 25 | -------- |
| 26 | |
| 27 | Using with the default prompt: |
| 28 | |
| 29 | :: |
| 30 | |
| 31 | => pause |
| 32 | Press any key to continue... |
| 33 | |
| 34 | |
| 35 | Using with a custom prompt: |
| 36 | |
| 37 | :: |
| 38 | |
| 39 | => pause 'Prompt for pause...' |
| 40 | Prompt for pause... |
| 41 | |
| 42 | Note that complex prompts require proper quoting: |
| 43 | |
| 44 | :: |
| 45 | |
| 46 | => pause Prompt for pause... |
| 47 | pause - delay until user input |
| 48 | |
| 49 | Usage: |
| 50 | pause [prompt] - Wait until users presses any key. [prompt] can be used to customize the message. |
| 51 | |
| 52 | Return value |
| 53 | ------------ |
| 54 | |
| 55 | The return value $? is always set to 0 (true), unless invoked in an invalid |
| 56 | manner. |