https://github.com/ryancurrah/weatherterm
Weather in your terminal!
https://github.com/ryancurrah/weatherterm
mac openweathermap powerlevel10k powerlevel9k shell terminal weather zsh
Last synced: 7 months ago
JSON representation
Weather in your terminal!
- Host: GitHub
- URL: https://github.com/ryancurrah/weatherterm
- Owner: ryancurrah
- Created: 2019-06-09T02:21:47.000Z (over 6 years ago)
- Default Branch: main
- Last Pushed: 2024-12-08T15:59:23.000Z (10 months ago)
- Last Synced: 2025-03-17T23:44:55.959Z (7 months ago)
- Topics: mac, openweathermap, powerlevel10k, powerlevel9k, shell, terminal, weather, zsh
- Language: Go
- Homepage:
- Size: 15.9 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# weatherterm
Weather in your terminal! This binary updates a `.weatherterm` file in your home directory that can be used in your terminal.
# Requirements
- [OpenWeatherMap](https://openweathermap.org/) API key
- `weatherterm` binary running in the background preferably as a service# Add to startup on mac
The install subcommand will create a plist service file. You will need to load and run it.
```shell
weatherterm run -country US -city Miami -key 0000000000000000000 -unit imperiallaunchctl load -w ~/Library/LaunchAgents/com.weatherterm.plist
launchctl start -w ~/Library/LaunchAgents/com.weatherterm.plist
```# Get it working with POWERLEVEL9k
In your .zshrc file add the following lines...
```shell
POWERLEVEL9K_CUSTOM_WEATHER="prompt_weather"
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(custom_weather)function prompt_weather() {
echo "$(cat "${HOME}/.weatherterm")"
}
```# Example
```shell
weatherterm run -country US -city Miami -key 0000000000000000000 -unit imperial
^Ccat ~/.weather
🌡 0.82 ⛅ 💨 7.72m/s SSW
```