A CLI tool to find specialty coffee shops near you
Project description
EspressoNow โ
Python CLI tool to find specialty coffee shops near your current location.
Features
- ๐ Auto-location detection - Automatically detects your current location
- ๐ Custom location search - Search near any address or coordinates
- โ Specialty coffee focus - Finds high-quality, specialty coffee shops
- ๐จ Beautiful output - Rich, colorful CLI interface with tables and progress bars
- ๐ Flexible search - Customizable search radius and result limits
- ๐บ๏ธ Google Places API integration - Real-time coffee shop data from Google's database
Installation
From Source
git clone https://github.com/ethanqcarter/EspressoNow.git
cd EspressoNow
pip install -e .
Dependencies
pip install -r requirements.txt
Quick Start
Configuration
Required: You'll need a Google Places API key to search for coffee shops:
- Get an API key at Google Places API
- Set it as an environment variable:
export GOOGLE_PLACES_API_KEY=your_key_here
- Or create a
.envfile:cp env.example .env # Edit .env and add your API key
Basic Usage
# Find coffee shops near your current location
espresso search
# Search with custom radius
espresso search --radius 5
# Search near a specific address
espresso search --location "123 Main St, San Francisco, CA"
# Search near coordinates
espresso search --location "37.7749,-122.4194"
Commands
search - Find coffee shops
espresso search [OPTIONS]
Options:
-r, --radius FLOAT Search radius in kilometers (default: 2.0)
-n, --max-results INTEGER Maximum number of results (default: 10)
-l, --location TEXT Search location (address or "lat,lng")
--api-key TEXT Google Places API key
--min-rating FLOAT Minimum rating (e.g., 4.0 for >4 stars)
--exclude-chains Exclude chain coffee shops (Starbucks, Dunkin, etc.)
--specialty-only Show only specialty coffee (4+ stars, no chains)
--help Show help message
config - Show configuration
espresso config
Shows current configuration status and setup instructions.
Examples
Find coffee shops near current location
espresso search
Search with 5km radius, max 20 results
espresso search --radius 5 --max-results 20
Search near specific coordinates (San Francisco)
espresso search --location "37.7749,-122.4194"
Search near coordinates (New York City)
espresso search --location "40.7128,-74.0060"
Find only specialty coffee (4+ stars, no chains)
espresso search --specialty-only
Exclude chain coffee shops
espresso search --exclude-chains
Use specific API key
espresso search --api-key your_google_places_api_key
Example Output
Here's what you'll see when searching for specialty coffee in San Francisco:
$ espresso search --location "37.7749,-122.4194" --radius 8 --specialty-only --max-results 5
Using provided coordinates: 37.7749, -122.4194
โ ธ Searching for coffee shops...
โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ Search Info โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ ๐ Search Location: 37.7749, -122.4194 โ
โ ๐ Search Radius: 8.0km โ
โ ๐ Results Found: 8 โ
โ ๐ง Filters: โญ Min Rating: 4.0 | ๐ซ Chains Excluded | โ Specialty Only โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
โ Specialty Coffee Shops Near You
โโโโโโโโโโโโโโโโโโโโโณโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโณโโโโโโโโโโโโโโโโโณโโโโโโโโณโโโโโโโโโโโณโโโโโโโโโโโโโโโโโ
โ Name โ Address โ Rating โ Price โ Distance โ Phone โ
โกโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฉ
โ Zuni Cafรฉ โ 1658 Market St, San Francisco, โ โญโญโญโญ (4.4) โ $$$ โ 242m โ (415) 552-2522 โ
โ โ CA 94102, USA โ โ โ โ โ
โ Sightglass Coffee โ 270 7th St, San Francisco, CA โ โญโญโญโญ (4.5) โ $$ โ 991m โ (415) 861-1313 โ
โ โ 93103, USA โ โ โ โ โ
โ Tartine Bakery โ 600 Guerrero St, San Francisco, โ โญโญโญโญ (4.5) โ $$ โ 1.6km โ (415) 487-2600 โ
โ โ CA 94110, USA โ โ โ โ โ
โ The Mill โ 736 Divisadero St, San โ โญโญโญโญ (4.5) โ $$ โ 1.6km โ (415) 345-1953 โ
โ โ Francisco, CA 94117, USA โ โ โ โ โ
โ Sweet Maple โ 2101 Sutter St, San Francisco, โ โญโญโญโญ (4.6) โ $$ โ 1.8km โ (415) 655-9169 โ
โ โ CA 94115, USA โ โ โ โ โ
โโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโดโโโโโโโโดโโโโโโโโโโโดโโโโโโโโโโโโโโโโโ
This example shows EspressoNow finding top-rated specialty coffee shops in San Francisco, including famous spots like Tartine Bakery, Sightglass Coffee, and The Mill - all with 4+ star ratings and no chain coffee shops included!
Output
EspressoNow displays results in a beautiful table format showing:
- โ Name - Coffee shop name
- ๐ Address - Street address
- โญ Rating - Star rating (1-5)
- ๐ฐ Price - Price level ($-$$$$)
- ๐ Distance - Distance from search location
- ๐ Phone - Contact number
API Integration
Google Places API (New)
EspressoNow uses the latest Google Places API (New) to find real coffee shops:
- POST-based Nearby Search with "cafe" and "coffee_shop" types
- Real-time data from Google's comprehensive database
- Detailed place information including ratings, prices, and contact details
- Supports up to 50km search radius
Note: A Google Places API key is required for the application to function.
Development
Project Structure
espressonow/
โโโ __init__.py # Package initialization
โโโ cli.py # Command-line interface
โโโ core.py # Core coffee shop finding logic
โโโ location.py # Location detection and services
โโโ models.py # Data models (Pydantic)
Running Tests
# Install in development mode
pip install -e .
# Test the CLI
espresso search --help
espresso config
# Test with API key
export GOOGLE_PLACES_API_KEY=your_key_here
espresso search --location "San Francisco, CA"
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
License
MIT License - see LICENSE file for details.
Support
- ๐ Issues: GitHub Issues
- ๐ง Contact: ethanqcarter@example.com
Made with โ and โค๏ธ by coffee enthusiasts, for coffee enthusiasts.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file espressonow-0.1.0.tar.gz.
File metadata
- Download URL: espressonow-0.1.0.tar.gz
- Upload date:
- Size: 13.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a8e9d4c8c0c9a595d0625867a674265d5753e46580a0d03a67e092bce7dbe45f
|
|
| MD5 |
f2053952eabdb442dc7874924ccadbdd
|
|
| BLAKE2b-256 |
ecf265a158ec8a47ff82a7302649eb20e1ed4ce5513952c5dc425ca2a367048d
|
File details
Details for the file espressonow-0.1.0-py3-none-any.whl.
File metadata
- Download URL: espressonow-0.1.0-py3-none-any.whl
- Upload date:
- Size: 13.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
459eca4fc2ddd57ec64ca6d98122a263cd5c9a9b7ff3a8735de810f0d2391068
|
|
| MD5 |
d10b25f88081ed2168521b3fbf4c03bd
|
|
| BLAKE2b-256 |
7222db2260e1f50a286c74ce0249c111067e7c9a6b4aff4debe6a8de5689c6d0
|