{
"info": {
"author": "Nathan Henrie",
"author_email": "nate@n8henrie.com",
"bugtrack_url": null,
"classifiers": [
"Natural Language :: English",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: Implementation :: PyPy"
],
"description": "NM Fishing Report\n=================\n\n|Build Status|\n\nScrapes the NM Dept of Game and Fish fishing report\n\n- Free software: MIT\n- Documentation: https://nmfishingreport.readthedocs.org\n\nFeatures\n--------\n\n- Scrapes fishing report into sqlite database\n- Writes to a text file the reports for a specified list of spots\n\n - Basic Markdown format\n - I use this to output to a Dropbox folder for easy access on mobile\n\n- Monitors for keywords and can optionally use a custom notification\n script when those keywords appear in a report\n\nIntroduction\n------------\n\nThe NM Dept of Game and Fish publishes `a biweekly fishing\nreport `__. This\nscript scrapes the report into a database so I can see how various spots\nfare throughout the year. It send me a\n`Pushover `__ notification whenever the report\nfor one of my favorite spots has any of the buzzwords I've selected.\n\nDependencies\n------------\n\n- Python3\n- OS X or Linux\n- See ``requirements.txt``\n\nQuickstart\n----------\n\n1. Copy ``config-sample.ini`` (recommended: rename to ``config.ini``,\n which is ``.gitignore``\\ d)\n2. Modify config (see section below)\n3. ``pip3 install nmfishingreport``\n4. ``python3 -m nmfishingreport -c /path/to/your-config.ini``\n\nDevelopment Setup\n~~~~~~~~~~~~~~~~~\n\n1. Clone the repo:\n ``git clone https://github.com/n8henrie/nmfishingreport && cd nmfishingreport``\n2. Make a virtualenv: ``python3 -m venv venv``\n3. Install dev setup: ``venv/bin/pip install .[dev]``\n\nConfiguration\n-------------\n\nI recommend you start with ``config-sample.ini``. I've tried to add\ncomments to make it somewhat self-explanatory. A few notes:\n\n- You'll need to make sure your spelling matches NMDGF for\n ``fav_spots``.\n- I've included my database file with some reports going back to 2015\n\n - There are likely several holes from times when the NMDGF updated\n their website and broke the script or times that my computer\n wasn't running\n - If you want to want to continue with my existing database, copy it\n to a more reasonable filename (recommended:\n ``fishing_reports.db``), and use it as ``db`` in your config\n - The filename ``fishing_reports.db`` is ``.gitignore``-d\n - I'll try to update the provided file from time to time\n\nNotification config\n~~~~~~~~~~~~~~~~~~~\n\nIf you know a bit of Python, you can optionally provide a notification\nscript if you want to get a push notification (or email or what have\nyou) when certain keywords show up in the report for one of your\n``fav_spots``. The file should expose a bare function ``notify`` that\naccepts two arguemnts:\n\n1. A dictionary containing the following keys:\n\n - ``spot``: the fishing spot triggering the notification\n - ``report``: the text of that spot's fishing report\n - ``url``: the URL for the fishing report\n\n2. The path to your config file\n\nBecause it accepts a path to your config file, you can add a section to\nyour config file to include usernames and passwords for the notification\nscript if needed. For example, in the ``extras/`` directory I've\nincluded my (working) ``notify.py`` for Pushover -- it pulls my Pushover\ncredentials from my config file, which is kept out of version control.\n\nBe forewarned that ``nmfishingreport`` loads the notification script to\n``exec``\\ ing its contents, which I'm sure could have security\nramifications or lead to data loss if you aren't careful. Leave the\n``NOTIFY`` section out of your config to avoid this entirely.\n\nAcknowledgements\n----------------\n\n- NM Dept of Game and Fish!\n\nTroubleshooting / FAQ / Examples\n--------------------------------\n\n- How can I get info out of an sqlite database?\n\n - I'm not terribly good at sqlite either, so here's how to convert\n it to a csv file that you can open in your spreadsheet app of\n choice:\n - ``sqlite3 -header -csv fishing_reports.db \"SELECT * FROM nm_fishing_reports;\" > fishingreport.csv``\n\n- Some other ideas on looking at the contents:\n\n - Dump all reports to your screen:\n\n - ``sqlite3 fishing_reports.db 'SELECT * FROM nm_fishing_reports;'``\n\n - Show the 10 most recent reports:\n\n - ``sqlite3 fishing_reports.db 'SELECT * FROM nm_fishing_reports ORDER BY date DESC LIMIT 10;'``\n\n - Show the 5 most recent reports for the Jemez waters:\n\n - ``sqlite3 fishing_reports.db 'SELECT date, report FROM nm_fishing_reports WHERE spot LIKE \"%Jemez%\" ORDER BY date DESC LIMIT 5;'``\n\n - Show the most recent spot to have had the word \"excellent\" in the\n report:\n\n - ``sqlite3 fishing_reports.db 'SELECT date, spot FROM nm_fishing_reports WHERE report LIKE \"% excellent %\" ORDER BY date DESC LIMIT 1;'``\n\n - Show what times of year the Jemez fishing has been \"very good\" or\n \"excellent\":\n\n - ``sqlite3 fishing_reports.db 'SELECT date FROM nm_fishing_reports WHERE (report LIKE \"% very good %\" OR report LIKE \"% excellent %\") AND spot LIKE \"%Jemez%\";'``\n\n- How can I run ``nmfishingreport`` automatically?\n\n - If you're on OS X, I've included an example launchd plist in\n ``extras/``\n\n.. |Build Status| image:: https://travis-ci.org/n8henrie/nmfishingreport.svg?branch=master\n :target: https://travis-ci.org/n8henrie/nmfishingreport\n\n\nHistory\n=======\n\n0.1.0 :: 20160613\n-----------------\n\n- First release on GitHub / PyPI.",
"description_content_type": null,
"docs_url": null,
"download_url": "",
"downloads": {
"last_day": -1,
"last_month": -1,
"last_week": -1
},
"home_page": "https://github.com/n8henrie/nmfishingreport",
"keywords": "nmfishingreport",
"license": "MIT",
"maintainer": "",
"maintainer_email": "",
"name": "nmfishingreport",
"package_url": "https://pypi.org/project/nmfishingreport/",
"platform": "UNKNOWN",
"project_url": "https://pypi.org/project/nmfishingreport/",
"project_urls": {
"Homepage": "https://github.com/n8henrie/nmfishingreport"
},
"release_url": "https://pypi.org/project/nmfishingreport/0.1.0/",
"requires_dist": [
"beautifulsoup4 (==4.4.1)",
"requests (==2.10.0)",
"flake8 (==2.5.4); extra == 'dev'",
"pytest (==2.9.1); extra == 'dev'",
"tox (==2.3.1); extra == 'dev'",
"twine (==1.6.5); extra == 'dev'",
"wheel (==0.26.0); extra == 'dev'"
],
"requires_python": "",
"summary": "Scrapes the NM Dept of Game and Fish fishing report",
"version": "0.1.0"
},
"last_serial": 2165326,
"releases": {
"0.1.0": [
{
"comment_text": "",
"digests": {
"md5": "4af2d8a571f3eef3d6997749a8ff2f3d",
"sha256": "65d9ec5dfdd4d5643e20885150696d405b529eafca261c09bd2cdaa8dbd5ef33"
},
"downloads": -1,
"filename": "nmfishingreport-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "4af2d8a571f3eef3d6997749a8ff2f3d",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 9944,
"upload_time": "2016-06-13T20:35:53",
"url": "https://files.pythonhosted.org/packages/a1/f7/9488a18acf496b6b6397d89f1266b299ee9fe13687885dbade05ed6e0e15/nmfishingreport-0.1.0-py3-none-any.whl"
}
]
},
"urls": [
{
"comment_text": "",
"digests": {
"md5": "4af2d8a571f3eef3d6997749a8ff2f3d",
"sha256": "65d9ec5dfdd4d5643e20885150696d405b529eafca261c09bd2cdaa8dbd5ef33"
},
"downloads": -1,
"filename": "nmfishingreport-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "4af2d8a571f3eef3d6997749a8ff2f3d",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 9944,
"upload_time": "2016-06-13T20:35:53",
"url": "https://files.pythonhosted.org/packages/a1/f7/9488a18acf496b6b6397d89f1266b299ee9fe13687885dbade05ed6e0e15/nmfishingreport-0.1.0-py3-none-any.whl"
}
]
}