Skip to content

ruslanlap/PowerToysRun-Weather

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

14 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🌦️ PowerToys Run: Weather Plugin

Weather Plugin Demo

Weather Icon

✨ Weather for PowerToys Run ✨

Get real-time weather information directly from PowerToys Run

PowerToys Compatible Platform License: MIT Maintenance C# Version PRs Welcome GitHub stars GitHub issues GitHub release (latest by date) GitHub all releases Made with Love Awesome

πŸ“‹ Table of Contents

πŸ“‹ Overview

Weather is a plugin for Microsoft PowerToys Run that allows you to quickly check weather conditions directly from your PowerToys Run interface. Simply type weather followed by a location to get real-time weather information, or set up favorite locations for instant access.

PowerToys

πŸ†• What's New in v1.0.1

  • 😎 Temperature Feeling Emojis - Added intuitive emoji indicators that show how the temperature feels
  • πŸ”§ Improved UI - Enhanced weather display with visual temperature indicators
  • πŸ› Bug Fixes - Various improvements and optimizations

⚑ Easy Install

Download Weather Plugin

Quick Installation Steps:
1. Download using the button above
2. Extract to %LOCALAPPDATA%\Microsoft\PowerToys\PowerToys Run\Plugins\
3. Restart PowerToys
4. Start using with Alt+Space then type weather

✨ Features

  • 🌍 Location-based Weather - Get weather for any city worldwide
  • 🏠 Default Location - Set your home location for quick access
  • ⭐ Favorite Locations - Save multiple locations for easy checking
  • 🧠 Smart Geolocation - Automatically detect your current location
  • 🌑️ Temperature Units - Choose between Celsius and Fahrenheit
  • 😎 Temperature Feeling Emojis - Intuitive visual indicators for temperature ranges
  • πŸ” Detailed Information - View comprehensive weather data including:
    • Current temperature
    • "Feels like" temperature
    • Humidity percentage
    • Wind speed and direction
    • Weather condition with icon
  • πŸ–ΌοΈ Visual Weather Window - See detailed weather in a dedicated window
  • πŸ”„ Auto-refresh - Weather data is cached but refreshed regularly
  • πŸ”‘ API Key Management - Easy setup with OpenWeatherMap API
  • πŸŒ“ Theme Support - Works with both light and dark PowerToys themes
  • πŸ•’ Location Time - Displays the current time at the weather location
  • 🎨 Beautiful Widget - Elegant popup window with modern UI design that works like a mini weather widget

🎬 Demo Gallery

🌍 Search Weather by City

Weather by City Demo

Simply type weather followed by a city name

🏠 Default Location Weather

Default Location Demo

Just type weather to see your default location's weather

⭐ Favorite Locations

Favorite Locations Demo

Quickly access weather for your saved favorite locations

πŸ–ΌοΈ Weather Details Window

Weather Widget Demo

View detailed weather information in a dedicated window

πŸš€ Installation

πŸ“‹ Prerequisites

πŸ“₯ Installation Steps

  1. Download the latest release from the Releases page
  2. Extract the ZIP file to:
    %LOCALAPPDATA%\Microsoft\PowerToys\PowerToys Run\Plugins\
    
  3. Restart PowerToys
  4. Open PowerToys Run and type weather to access the plugin
  5. Enter your OpenWeatherMap API key in the plugin settings

πŸ”§ Usage

  1. Open PowerToys Run (default: Alt + Space)
  2. Use the following commands:
Command Description Example
weather Show weather for default or current location weather
weather <city> Show weather for a specific city weather London
weather <city>, <country> Show weather for a specific city with country code weather London, UK

🎯 Quick Tips

  • Press Enter on a weather result to open the detailed weather window
  • Right-click on a weather result for additional options
  • Set your favorite locations in the plugin settings for quick access
  • The plugin caches weather data to minimize API calls
  • Weather data is automatically refreshed when needed

πŸ“ Data Storage

The Weather plugin stores the following data locally:

  • Your OpenWeatherMap API key
  • Default location
  • Favorite locations
  • Temperature unit preference (Celsius/Fahrenheit)
  • Cached weather data (temporary)

All settings are stored securely in the PowerToys settings file.

πŸ› οΈ Building from Source

  1. Clone the repository:

    git clone https://github.com/ruslanlap/PowerToysRun-Weather.git
    
  2. Open the solution in Visual Studio 2022 or later

  3. Build the solution:

    dotnet build Weather/Weather.sln
    
  4. Run the build-and-zip script to create installation packages:

    ./build-and-zip.sh
    

πŸ“Š Project Structure

Weather/
β”œβ”€β”€ Community.PowerToys.Run.Plugin.Weather/
β”‚   β”œβ”€β”€ Images/                  # Plugin icons
β”‚   β”œβ”€β”€ Main.cs                  # Main plugin logic
β”‚   β”œβ”€β”€ WeatherResultWindow.xaml # Weather details window
β”‚   β”œβ”€β”€ plugin.json             # Plugin metadata
β”‚   └── ...
β”œβ”€β”€ Community.PowerToys.Run.Plugin.Weather.UnitTests/
β”‚   └── ...                      # Unit tests
└── Weather.sln                  # Solution file

🀝 Contributing

Contributions are welcome! Here's how you can help:

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/amazing-feature
  3. Commit your changes: git commit -m 'Add amazing feature'
  4. Push to the branch: git push origin feature/amazing-feature
  5. Open a Pull Request

Please make sure to update tests as appropriate.

Contributors

❓ FAQ

How do I get an OpenWeatherMap API key?

Visit OpenWeatherMap, create a free account, and generate an API key. The free tier allows up to 1,000 API calls per day, which is more than enough for personal use.

Why does the plugin need my location?

The plugin uses your location only to provide weather information for your current area when no specific location is requested. This is optional - you can set a default location instead.

How often is the weather data updated?

Weather data is cached for 30 minutes to reduce API calls. After that time, new data will be fetched automatically.

Can I use this plugin offline?

The plugin requires internet access to fetch weather data. However, it will display cached data if available when offline.

How can I change from Celsius to Fahrenheit?

Open the plugin settings by typing "weather settings" in PowerToys Run, then toggle the temperature unit option.

✨ Why You'll Love Weather Plugin

  • Saves Time: Check the weather without opening a browser or app
  • Keyboard-Centric: Perfect for keyboard power users
  • Customizable: Set your preferred locations and units
  • Fast: Instant access to weather information
  • Beautiful: Clean, modern UI that matches PowerToys style
  • Privacy-Focused: No tracking, only uses location when needed
  • Resource-Efficient: Lightweight with minimal system impact

πŸ“„ License

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

πŸ™ Acknowledgements

πŸ› οΈ Implementation Details

The Weather plugin is built using:

  • C# and .NET
  • WPF for the UI components
  • HttpClient for API communication
  • System.Text.Json for JSON parsing
  • Task-based asynchronous pattern for non-blocking operations

The plugin implements several PowerToys Run interfaces:

  • IPlugin - Core plugin functionality
  • IContextMenu - Right-click context menu
  • IDisposable - Resource cleanup
  • IPluginI18n - Internationalization support
  • ISettingProvider - Settings management

Roadmap

  • Multiple day forecast
  • Weather alerts and notifications
  • More unit options (wind speed, pressure)
  • Custom themes for weather window
  • Additional weather providers
  • Offline mode improvements
  • Location autocomplete
  • Weather maps integration