Skip to content

ybarsotti/tmux-currency

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tmux-currency 📈💰

A Tmux plugin that displays (almost)real-time currency exchange rates in the status bar, powered by AwesomeAPI.

license


📥 Installation

🔹 Using TPM (Tmux Plugin Manager)

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

🔹 Manual Installation

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 config file

Update the .tmux.conf file adding the key into the status

set -g status-right "#{currency}"

Reload Tmux:

tmux source ~/.tmux.conf

⚙️ Configuration

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

💱 Available currencies

In the AwesomeAPI documentation you can find all available currencies.

🖥️ Screenshots

Example

🛠️ How It Works

  1. The plugin fetches exchange rates from AwesomeAPI.
  2. It processes the response and formats the data for display.
  3. The formatted currency rates are displayed in the Tmux status bar.
  4. Updates occur at the interval set in @tmux-currency-update-interval.
  5. It caches prices according to the interval set

📝 License

This project is licensed under the MIT License. See the LICENSE file for details.

📄 Credits

  • Thanks to AwesomeAPI for providing the APIs ❤️

About

A Tmux plugin to monitor currency prices.

Topics

Resources

License

Stars

Watchers

Forks

Languages