Make weather widgets location- and units-aware#5745
Open
twagner12 wants to merge 5 commits into
Open
Conversation
`omarchy-weather-icon` and `omarchy-weather-status` now read `~/.config/omarchy/current/weather.location` when present and pass it to wttr.in. When the file is absent or empty, the URL is unchanged (`https://wttr.in?format=...`) and behavior is identical to before, so auto-detect remains the default. Adds four small CLI commands: omarchy weather location show current value omarchy weather set-location <x> persist <x> (city, "City, ST", or zip) omarchy weather clear-location delete the file, return to auto-detect omarchy menu weather walker prompt that calls set-location No `omarchy-menu` wiring; users can keybind `omarchy menu weather` or run it from the CLI. Spaces in locations are encoded as `+` for wttr.in.
Contributor
There was a problem hiding this comment.
Copilot wasn't able to review any files in this pull request.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Menu structure based on basecamp#5714 by NjengaFelix. Co-Authored-By: Felix Njenga <32095327+NjengaFelix@users.noreply.github.com>
3559a45 to
005be46
Compare
Wires `omarchy-menu weather` to open the Weather setup submenu (Location, Units) so it can be bound to waybar's right-click handler.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The weather widgets currently auto-detect both location and units from geo-IP, which fails on VPNs and on US locations that prefer metric (or vice versa). This adds:
Location
omarchy weather location/set-location/clear-locationomarchy menu weatherUnits
omarchy weather units/set-units (metric|imperial)/clear-unitsThe Weather setup submenu now also dispatches via
omarchy-menu weather, so a waybar right-click can be bound straight to it.When no value is configured, behavior is identical to today — wttr.in auto-detects from the request.