-
-
Notifications
You must be signed in to change notification settings - Fork 666
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
24014b2
commit 5f8d238
Showing
1 changed file
with
7 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,15 @@ | ||
### Using the Progress Bar Script | ||
# Using the Progress Bar Script | ||
|
||
#### Description | ||
### Description | ||
|
||
This script provides a simple progress bar TUI for the terminal platform. It allows you to visualize the progress of a task being executed in your shell script. | ||
|
||
#### Usage | ||
|
||
1. **Copy Functions:** | ||
|
||
- Copy the `delay` and `progress` functions directly into your shell script. | ||
|
||
2. **Invoke `progress` Function:** | ||
- Call the `progress` function within your script to display the progress bar. | ||
|
||
#### Steps | ||
|
||
1. **Copy Functions:** | ||
|
||
- Copy the `delay` and `progress` functions from the script provided into your own shell script. These functions handle the delay and printing of the progress bar. | ||
|
||
2. **Invoke `progress` Function:** | ||
|
||
- Within your script, call the `progress` function whenever you want to display the progress bar. | ||
- Pass two parameters to the `progress` function: | ||
- `PARAM_PROGRESS`: The progress percentage (0-100) of the task. | ||
- `PARAM_STATUS`: Optional. A status message to display alongside the progress bar. | ||
|
||
```bash | ||
# Example usage: | ||
progress 25 "Processing data..." # Displays a 25% progress bar with the status "Processing data..." | ||
``` | ||
|
||
#### Example | ||
|
||
```bash | ||
#!/bin/bash | ||
# Copy the delay and progress functions here | ||
# Your script logic here | ||
# Invoke the progress function to display the progress bar as your script progresses | ||
# Example: | ||
progress 25 "Processing data..." # Display a 25% progress bar with the status "Processing data..." | ||
This line might start to look like this its location is usually here: `.bashrc` `.bash_profile`. | ||
```shell | ||
plugins = (git bundler osx rake ruby) | ||
``` | ||
_⚠️ if you want to only add the plugin(s) and not oh-my-bash you can copy it and paste it directly into .bashrc or .bash_profile. by doing this the plugins will not receive updates, the errors will have to be solved by you_ | ||
|
||
|
||
This will visually represent the progress of your script's execution in the terminal. Adjust the `progress` function calls according to the progress of your task. |