# PyNews-Google
A Python library to fetch and parse Google News feeds.
## Installation
```
pip install pynews-google
```
## Usage
### As a library
```python
from pynews_google import GoogleNews
news = GoogleNews()
# Get top news
top_news = news.top_news()
# Get topic headlines
tech_news = news.topic_headlines('TECHNOLOGY')
# Search news
search_results = news.search('Python programming')
# Print results
for entry in top_news['entries']:
print(f"Title: {entry['title']}")
print(f"Link: {entry['link']}")
print(f"Published: {entry['published']}")
print("---")
```
### As a CLI
```
pynews-google top
pynews-google topic --topic TECHNOLOGY
pynews-google search --query "Python programming"
```
## Features
- Fetch top news from Google News
- Get headlines for specific topics
- Search for news articles
- Command-line interface for quick access to news
## Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
## License
This project is licensed under the MIT License - see the LICENSE file for details.
## Author
Amos Maru
## Acknowledgments
- Google News for providing the RSS feeds
- All contributors who help improve this library
Raw data
{
"_id": null,
"home_page": "https://github.com/AmosMaru/googlenews",
"name": "pynews-google",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": null,
"keywords": null,
"author": "Amos Maru",
"author_email": "amosmaru10@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/30/78/3c0be50e2ebc4257b1f3393086196f85c086b47bb4320c0af16960e55326/pynews-google-0.1.2.tar.gz",
"platform": null,
"description": "# PyNews-Google\n\nA Python library to fetch and parse Google News feeds.\n\n## Installation\n\n```\npip install pynews-google\n```\n\n## Usage\n\n### As a library\n\n```python\nfrom pynews_google import GoogleNews\n\nnews = GoogleNews()\n\n# Get top news\ntop_news = news.top_news()\n\n# Get topic headlines\ntech_news = news.topic_headlines('TECHNOLOGY')\n\n# Search news\nsearch_results = news.search('Python programming')\n\n# Print results\nfor entry in top_news['entries']:\n print(f\"Title: {entry['title']}\")\n print(f\"Link: {entry['link']}\")\n print(f\"Published: {entry['published']}\")\n print(\"---\")\n```\n\n### As a CLI\n\n```\npynews-google top\npynews-google topic --topic TECHNOLOGY\npynews-google search --query \"Python programming\"\n```\n\n## Features\n\n- Fetch top news from Google News\n- Get headlines for specific topics\n- Search for news articles\n- Command-line interface for quick access to news\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## License\n\nThis project is licensed under the MIT License - see the LICENSE file for details.\n\n## Author\n\nAmos Maru\n\n## Acknowledgments\n\n- Google News for providing the RSS feeds\n- All contributors who help improve this library\n\n",
"bugtrack_url": null,
"license": null,
"summary": "A Python library to fetch and parse Google News feeds",
"version": "0.1.2",
"project_urls": {
"Homepage": "https://github.com/AmosMaru/googlenews"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "e2ac2044804ce6d227395dba4a772bc2406efbf57ecd252c4edde4c2fe965d42",
"md5": "6b9e84e8a153a39f3ab5ad22d4033709",
"sha256": "b1e322eeb78af518c24f3ce3a747d42da4d286a3034b11c318350cfbd25b8676"
},
"downloads": -1,
"filename": "pynews_google-0.1.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "6b9e84e8a153a39f3ab5ad22d4033709",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 4955,
"upload_time": "2024-09-25T21:17:54",
"upload_time_iso_8601": "2024-09-25T21:17:54.528636Z",
"url": "https://files.pythonhosted.org/packages/e2/ac/2044804ce6d227395dba4a772bc2406efbf57ecd252c4edde4c2fe965d42/pynews_google-0.1.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "30783c0be50e2ebc4257b1f3393086196f85c086b47bb4320c0af16960e55326",
"md5": "5839573e1c9391c08d0f49184f67bc4e",
"sha256": "15676a9fcab28684179a3ee5b1019e5d48e98a3c394e4478604bb9a84b8052b3"
},
"downloads": -1,
"filename": "pynews-google-0.1.2.tar.gz",
"has_sig": false,
"md5_digest": "5839573e1c9391c08d0f49184f67bc4e",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 4137,
"upload_time": "2024-09-25T21:17:56",
"upload_time_iso_8601": "2024-09-25T21:17:56.097082Z",
"url": "https://files.pythonhosted.org/packages/30/78/3c0be50e2ebc4257b1f3393086196f85c086b47bb4320c0af16960e55326/pynews-google-0.1.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-09-25 21:17:56",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "AmosMaru",
"github_project": "googlenews",
"github_not_found": true,
"lcname": "pynews-google"
}