Interactive Live Weather App

Batch Script Weather Application

About This Project

This is a simple Interactive Live Weather App built using a Batch script. The app allows users to fetch live weather data for any city, state, or country directly from the command line.

The application uses the wttr.in API to retrieve real-time weather information and displays it in a user-friendly format in the terminal. You can fetch weather data for multiple locations in one go.

Technologies Used

Batch Script
wttr.in API
cURL
Windows CMD

Key Features

  • Live Weather Data: Fetch real-time weather information for any location
  • Multiple Locations: Get weather data for multiple cities, states, or countries in one go
  • Simple Interface: Easy-to-use command-line interface
  • No Installation Required: Just create a .bat file and run it
  • Lightweight: Minimal resource usage with instant results
  • Cross-Location Support: Works for cities, states, and countries worldwide

How to Create and Run

Step 1: Create a Batch File

Open Notepad or any text editor of your choice.

Step 2: Write the Code

This script will prompt the user to enter a city name, then fetch and display the live weather for the entered city.

Example: curl wttr.in/Gujarat

You can fetch the live weather for multiple cities, states, or countries in one go by specifying each location.

Step 3: Save and Run the File

When saving the file, go to File > Save As. In the Save As window, change "Save as type" from "Text Documents (*.txt)" to "All Files". Name the file weather.bat.

Run: Double-click the .bat file to open and run the app.

What I Learned

  • Batch scripting fundamentals and command-line automation
  • Working with external APIs using cURL commands
  • Creating interactive command-line applications
  • User input handling in batch scripts
  • Windows command prompt scripting techniques
  • Real-time data fetching and display