A Tmux plugin that displays (almost)real-time currency exchange rates in the status bar, powered by AwesomeAPI.
If you use TPM, add the
following line to your .tmux.conf
:
set -g @plugin 'ybarsotti/tmux-currency'
Then, reload Tmux and install the plugin:
tmux source ~/.tmux.conf
<tmux-prefix> + I
Clone the repository into your Tmux plugins directory (usually ~/.tmux/plugins/):
git clone https://github.com/ybarsotti/tmux-currency ~/.tmux/plugins/tmux-currency
Then, add this line to your .tmux.conf:
run-shell ~/.tmux/plugins/tmux-currency/tmux-currency.tmux
Update the .tmux.conf
file adding the key into the status
set -g status-right "#{currency}"
Reload Tmux:
tmux source ~/.tmux.conf
You can customize the plugin by setting the following Tmux options in your .tmux.conf:
Option | Default | Description |
---|---|---|
@tmux-currency-currencies | USD-BRL | A comma-separated list of currency pairs (e.g., USD-BRL,BTC-BRL) |
@tmux-currency-update-interval | 60 | Update interval in seconds |
Example configuration:
set -g @tmux-currency-currencies "USD-BRL,BTC-BRL"
set -g @tmux-currency-update-interval 30
In the AwesomeAPI documentation you can find all available currencies.
- The plugin fetches exchange rates from AwesomeAPI.
- It processes the response and formats the data for display.
- The formatted currency rates are displayed in the Tmux status bar.
- Updates occur at the interval set in @tmux-currency-update-interval.
- It caches prices according to the interval set
This project is licensed under the MIT License. See the LICENSE file for details.
- Thanks to AwesomeAPI for providing the APIs ❤️