Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rlopzc/waybar-wise-fx-rate
Waybar module to display FX rate between two currencies using the Wise API.
https://github.com/rlopzc/waybar-wise-fx-rate
cli fx-rate fx-rates waybar waybar-module zig
Last synced: about 1 month ago
JSON representation
Waybar module to display FX rate between two currencies using the Wise API.
- Host: GitHub
- URL: https://github.com/rlopzc/waybar-wise-fx-rate
- Owner: rlopzc
- Created: 2024-07-03T04:29:26.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2024-07-16T02:56:23.000Z (4 months ago)
- Last Synced: 2024-07-16T16:01:34.134Z (4 months ago)
- Topics: cli, fx-rate, fx-rates, waybar, waybar-module, zig
- Language: Zig
- Homepage:
- Size: 43 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Waybar Wise FX Rate
Waybar module to get the FX rate between two currencies using the Wise API.
Example output in Waybar:
```
17.62 USD/MXN
```## Getting Started
### Get your Wise API Key
In order for this to work, you need to provide your Wise API Key.
1. Log in to wise.
1. Go to: Profile -> Settings -> Developer tools -> API tokens.
1. Add new token
1. _Name_: Waybar Wise FX Rate.
1. _Token permissions_: **Read only** <- Very important!!
1. Click _Create token_.
1. Copy your token### Compile and install the binary
```sh
# Clone the repo
git clone https://github.com/rlopzc/waybar-wise-fx-rate.gitcd waybar-wise-fx-rate
# Build the binary
zig build --release=fast
```The binary will be in `zig-out/bin/waybar-wise-fx-rate`.
Symlink it to your `~/.local/bin`. Replace `` with the dir where you cloned the repository.
```sh
ln -s $HOME//zig-out/bin/waybar-wise-fx-rate ~/.local/bin/waybar-wise-fx-rate
```### Downloading binary from Releases
Currently built for:
- x86_64-linux
- aarch64-linux
- arm-linux1. Check your architecture.
1. Download it with `curl -L https://github.com/rlopzc/waybar-wise-fx-rate/releases/latest/download/waybar-wise-fx-rate-x86_64-linux > waybar-wise-fx-rate`.
1. Make it executable `chmod +x ./waybar-wise-fx-rate`.
1. Symlink it with: `ln -s $HOME//waybar-wise-fx-rate ~/.local/bin/waybar-wise-fx-rate`.> Replace the architecture with yours.
## Using the Waybar module
**CLI Arguments**.
- `--apikey`. Wise API key.
- `--source`. Source Currency supported by Wise.
- `--target`. Target Currency supported by Wise.Add a custom module to your waybar config:
```json
"custom/wise-fx-rate": {
"format": "{} {icon}",
"return-type": "json",
"format-icons": {
"default": "$"
},
"exec": "waybar-wise-fx-rate --apikey --source --target ",
"interval": 60
}
```