Repository navigation
Releases: GenMoz22/WeatherTUI-Go
Release list
v1.0.5
[1.0.5] - 2026-09-27
New Features
-
Apparent Temperature Engine (
CalculateApparentTemperature)- Computes "feels like" temperatures (°C/°F) using real-time temperature, relative humidity, and wind speed metrics.
- Incorporates Wind Chill dynamics for temperatures
$\le 10^\circ\text{C}$ with wind speeds$> 4.8\text{ km/h}$ . - Applies Rothfusz Heat Index approximations for warm and humid conditions (
$\ge 27^\circ\text{C}$ with relative humidity$\ge 40%$ ). - Handles seamless fallbacks to real temperatures when atmospheric thresholds are not met.
-
Smart UI "Feels Like" Display
- Evaluates variance using
math.Abs(rawCelsius - rawApparentCelsius) >= 0.5. - Appends
(feels X.X °C)/(feels X.X °F)only when the perceived temperature significantly diverges from the real temperature. Omits redundant indicators when identical.
- Evaluates variance using
-
Geographical Telemetry in Status Bar
- Displays active latitude and longitude coordinates in the bottom status bar alongside terminal dimensions.
- Dynamic styling: coordinates render in yellow for favorited locations and cyan for standard searches.
-
WMO ASCII Art Icons
- Integrated World Meteorological Organization (WMO) codes into the Open-Meteo payload.
- Renders dedicated ASCII condition art alongside weather condition labels in the main atmosphere monitor panel.
-
Adaptive Small Screen Layout (
renderSmallScreenLayout)- Triggers a compact vertical layout when terminal dimensions collapse below
80x20. - Preserves screen real estate by rendering the search input, current weather monitor, and favorites/history panels while gracefully hiding the 14-day forecast table.
- Progressively reveals extra telemetry metrics (UV index, AQI, moon phase, sunset/sunrise times, and ASCII icons) as vertical space allows.
- Triggers a compact vertical layout when terminal dimensions collapse below
Performance & Core Architecture
-
Cache Garbage Collection
- Introduced a ticker-driven background goroutine in
CacheServicethat periodically sweeps in-memory entries and evicts stales beyond the 30-minute TTL threshold to eliminate memory leaks.
- Introduced a ticker-driven background goroutine in
-
Thread-Safe Deep Copies
- Added
deepCopyResponsehelper toCacheService.GetandCacheService.Putto protect underlying slices against data races in concurrent contexts.
- Added
-
Decoupled Location Resolution
- Split
WeatherClientorchestration into discreteResolveLocationandFetchForecastByLocationsteps, enabling incremental TUI updates during async fetches.
- Split
-
Cache Service Accessor
- Exposed a clean accessor on
WeatherClientto grant callers controlled direct access to the internal cache service.
- Exposed a clean accessor on
Commits
- d7b2b39 docs(readme): align document
- db7b242 docs(readme): fix document
- b9dc8ed docs(readme): update API reference, cache documentation and key features
- 5af51a2 docs(readme): update features, API documentation, and terminal dimension guard
- 49322e7 feat(cache): add background garbage collector worker for expired entries
- 38a9dce feat(ui): add ASCII weather condition icons driven by WMO codes
- 1abdd65 feat(ui): add apparent temperature calculation to atmosphere monitor panel
- 18a493e feat(ui): add responsive layout for small terminal screens
- 3cea214 feat(ui): display coordinates in footer status bar with favorite highlight
- 06cb7bb feat(ui): dynamic metric ordering in compact layout
- 1c7bf1d refactor(weather): implement deep copy cache and decoupled geocoding pipeline
- 818d5db style(ui): enhance partly cloudy ASCII icon rendering
v1.0.4
[1.0.4] - 2026-09-21
New Features
-
Direct Panel Navigation Shortcuts: Added numerical shortcuts to quickly switch panel focus when the search input is unfocused:
-
1to focus Search -
2to select Recent/Favorites -
3to target the Forecast panel
Updated panel headers and the built-in help menu to reflect these new navigation indicators. -
Direct Coordinate Parsing: Integrated RegEx detection for latitude and longitude pairs inside the search input. Valid coordinates now bypass text-based geocoding API calls and query weather endpoints directly.
-
24-Hour Thermal Trend Panel: Introduced a new hourly thermal trend view inside the forecast panel, toggling via the
vkey. Fetches hourly temperature telemetry from Open-Meteo and renders a thermal curve using Braille sparkline characters. -
Moon Phase Visuals: Added moon illumination percentage calculation and Unicode phase icon rendering within the atmospheric telemetry view.
-
Enhanced UV Index Output: Updated
GetUVIndexDescto display a styled block progress bar (e.g.,[████░░░░░░]) alongside the numeric UV index value and severity category label.
Visual & UI Improvements
- Refactored Panel Borders: Integrated box titles directly into the top border frame inside
RenderPanelBoxfor a cleaner UI layout. - Dynamic Layout Truncation: Added dynamic string truncation to panel titles and content rows based on terminal width, preventing layout clipping and boundary overflows in the atmosphere monitor box when handling long location names or status badges.
- Improved Selection Styles: Enhanced row selection indicators and background highlighting across all list components.
- Precipitation Bar Styling: Adjusted precipitation bar fill colors to use discrete active and background styles.
Refactoring & Improvements
- Imperial Unit System Renaming: Renamed
UseFahrenheittoImperialacrossConfigandModelstructs for clearer configuration keys and JSON mapping. Updated configuration persistence and UI rendering logic accordingly. - Wind Speed Conversions: Added a
KmHToMphconversion helper. Pressingunow toggles wind speed metrics to MPH alongside temperature unit changes in the atmospheric panel. - Location Name Standardization:
- Configured
WeatherMsgto register fully resolved location names in recent history. - Standardized favorite keybindings to utilize resolved city names consistently.
Commits
- 79d5412 feat(ui): add 24h hourly temperature trend view with sparklines
- 42965cb feat(ui): add block progress bar for UV index rendering
- ff0317e feat(ui): add direct panel shortcuts 1, 2, and 3
- caef230 feat(ui): convert wind speed to mph when toggling imperial units
- 06d94e8 feat(weather): add direct coordinate lookup support in search panel
- 3df888e feat(weather): compute and display current moon phase and illumination
v1.0.3
[1.0.3] - 2026-09-16
New Features & UI Enhancements
-
Recent Locations & Favorites: Added a recent locations history (max 3 slots) with duplicate prevention, and the ability to mark a city as a favorite (
pkey) to pin it with a[FAV]symbol. -
Persistent Preferences: Automatically saves and restores your unit preference (°C/°F), favorite city, and search history to
~/.config/WeatherTUI/config.jsonvia a newConfigManager. - Smart Startup Loading: Automatically resolves and loads weather metrics for your favorite city upon launch, falling back to your most recent search.
-
Interactive Modal Keybindings: Added a comprehensive keybindings legend overlay toggled via
?(dismissible via?,Esc, orq), styled using Lip Gloss placement primitives. -
Enhanced Navigation & Panel Switching:
- Implemented panel switching via
Tabwith active border styling. - Added Vim-style (
j/k) row navigation for the 14-day forecast table and recent locations list. - Added manual refresh and cache bypass via the
rkey.
- Implemented panel switching via
-
Atmospheric Telemetry & Dynamic Styling:
- Added wind direction parsing with degree-to-compass conversion using ASCII arrows (
$\uparrow, \nearrow, \rightarrow, \searrow, \downarrow, \swarrow, \leftarrow, \nwarrow$ ). - Implemented color-coded threat thresholds for UV index, relative humidity, and wind speed indicators.
- Added dynamic temperature styling (<0°C blue, 0–15°C cyan, 15–25°C green, 25–30°C orange, >=30°C red) applied to current metrics and the forecast table.
- Added wind direction parsing with degree-to-compass conversion using ASCII arrows (
- Responsive Design Guards: Added an early guard condition to render a fallback message ("Terminal screen too small. Please resize.") if the terminal dimensions drop below 80x20.
Bug Fixes & Improvements
- Geocoding & Caching: Persisted the resolved geocoded city name (
City, Country) inside the cachedWeatherResponseobject so subsequent cache hits return the formatted name instead of raw user input. Clean search terms are saved to history rather than the formatted API name to prevent re-fetching failures. - Refined
EscHandling: UpdatedEscbehavior inmain.goto blur the text input and switch focus back to the forecast panel when inside the search panel, preserving application exit functionality when the search panel is inactive. - UI Status Bar: Displayed the explicit
Ctrl+Cexit shortcut alongside theEscunfocus hint in the search panel status bar.
Project Structure & Refactoring
- Modular Architecture: Extracted Lipgloss model, view, and update UI logic from
main.gointo theinternal/ui/package. - Style Isolation: Moved Lipgloss style and color definitions to
internal/ui/styles.go. - Helper Utilities: Extracted temperature unit conversion, directional degree calculation, and dynamic threshold style resolvers into
internal/ui/helpers.go.
Commits
- a3412a7 Merge branch 'refactor'
- db56224 docs(readme): align document
- 9c14daf docs(readme): align document
- 0d13d5e docs(readme): align document
- 091ba67 feat(config): add favorite location and JSON config persistence
- b771be9 feat(tui): add contextual help overlay modal with '?' toggle
- db78bd6 feat(tui): add panel navigation, unit toggle and cache refresh
- c047732 feat(tui): add recent locations panel with navigation and reload support
- 731a373 feat(tui): add terminal dimension guards and max layout bounds
- a930fef feat(tui): defocus search input on esc keypress
- 75ff4b5 feat(ui): add dynamic color styling for humidity and wind metrics
- 92b2797 feat(ui): add wind direction ASCII arrows and dynamic temperature styling
- dd65395 feat(ui): extend atmosphere monitor with wind direction and uv index indicators
- 396c3cf fix(cache): preserve formatted city name in weather response on cache hit
- 0eb71b9 refactor(api): Moved 'weather' and renamed it to the standard name
- 290752a refactor(ci): restrict release targets to linux only
- 8105f4e refactor(config): Moved 'config'
- ee21bfd refactor(config): move config file location to ~/.local/share/WeatherTUI
- f688316 refactor(main): Removed duplicate functions from the main
- fb3207f refactor(ui): extract UI helper functions and styles to internal/ui package
- c03bebc refactor(ui): extract model logic to internal/ui package
- 4490b0f refactor(ui): extract update logic to internal/ui package
- 65e3d22 refactor(ui): extract view logic to internal/ui package
- 3326609 refactor(ui): move [CACHE HIT] badge into monitor panel header
v1.0.2
[1.0.2] - 2026-09-06
Added
- Integrated
bubbles/spinnerto provide feedback during asynchronous loading - Implemented
getSystemLanguage()to parse POSIX environment variables (LANG,LC_ALL, etc.) - Dynamic language parameter inclusion in geocoding diagnostic logs
Improved & Changed
- Replaced hardcoded
language=itin the Open-Meteo geocoding URL with dynamic system locale - Added automatic fallback to
enwhen system locale variables are absent - Enhanced responsive grid layout calculations in
View() - Standardized all code comments and structured
sloglogging messages - Embedded location metadata directly into the panel title header (
MONITOR: <City> (<Country>) - ATMOSPHERE)
Fixed & Safeguarded
- Added conditional error border styles for the current weather telemetry panel
- Safeguarded array access during daily metrics parsing in
GetWeather
Commits
- 6dcf148 chore(git): improve .gitignore structure
- 6c08509 docs(readme): update README
- f6448d5 edit: Updated README
- 2fbb130 feat(api): dynamically detect system language for geocoding accuracy
- 28a78ae feat(ui): add animated loading spinner and improve TUI responsive layout
- 9a56783 style(ui): embed target location into monitor panel title header
v1.0.1
v1.0.0
Changelog
- 2bad251 Aggiunta CI/CD
- 6b448c6 Update README.md
- ae6c4e0 Update README.md
- 2ae91b7 Update README.md
- 607c003 Update main.go
- 9e21443 Update main.go
- bd3a733 add: .gitignore
- 9e962a3 add: cache.go
- a786d36 add: dipendenze
- 67a3775 add: main.go
- dccaf2c add: readme
- ca5ad05 add: weather.go
- d988060 edit: .gitignore
- 7f66c53 edit: .gitignore