Skip to content

Commit

Permalink
make docs readable on pypi
Browse files Browse the repository at this point in the history
and update license
  • Loading branch information
fitnr committed Dec 16, 2014
1 parent 0014c08 commit 551c969
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 51 deletions.
22 changes: 0 additions & 22 deletions LICENSE

This file was deleted.

34 changes: 14 additions & 20 deletions buoyant/buoy.py
Original file line number Diff line number Diff line change
@@ -1,24 +1,18 @@
# -*- coding: utf-8 -*-
# The MIT License (MIT)
# Copyright (c) 2014 Neil Freeman

# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:

# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.

# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
# Copyright 2014 Neil Freeman
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.

# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.

# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.


from lxml import etree
from datetime import datetime
Expand Down
17 changes: 12 additions & 5 deletions readme.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
## Buoyant

Python wrapper for grabbing buoy data from the [National Buoy Data Center](https://www.ndbc.noaa.gov).

This package works by parsing XML from a NBDC endpoint. This isn't fully documented, so there's no guarantee of its stability.
Buoyant is a Python wrapper for grabbing buoy data from the [National Buoy Data Center](https://www.ndbc.noaa.gov). It parses XML from a NBDC endpoint. This data source isn't fully documented, so there's no guarantee of its stability.

The NBDC provides a [list](https://www.ndbc.noaa.gov/to_station.shtml) and a [map](https://www.ndbc.noaa.gov/obs.shtml) of active buoys.

Expand Down Expand Up @@ -123,15 +121,24 @@ Water quality data isn't included in the XML data source. Neither is the elevati

### XML

Get the raw XML, if you like XML for some reason. Maybe the package is missing something? If so, submit an issue or pull request!
Get the raw XML, if you like XML for some reason. Maybe the package is missing something? If so, submit an [issue](https://github.com/fitnr/buoyant/issues) or [pull request](https://github.com/fitnr/buoyant/pulls)!

````python
soul = Buoy('13010')
soul.xml
u'<?xml version="1.0" encoding="UTF-8"?>\n<observation id="13010" name="Soul" lat="-0.01" lon="0.00">\n <datetime>2014-12-16T02:00:00UTC</datetime>\n <winddir uom="degT">190</winddir>\n <windspeed uom="kt">9.9</windspeed>\n <airtemp uom="F">78.8</airtemp>\n</observation>\n'
'''<?xml version="1.0" encoding="UTF-8"?>
<observation id="13010" name="Soul" lat="-0.01" lon="0.00">
<datetime>2014-12-16T02:00:00UTC</datetime>
<winddir uom="degT">190</winddir>
<windspeed uom="kt">9.9</windspeed>
<airtemp uom="F">78.8</airtemp>
</observation>'''
````

### Compatibility

Buoyant is compatible with Python 2 and 3.

### License

Buoyant is licensed under the [GPL](https://www.gnu.org/licenses/#GPL).
24 changes: 20 additions & 4 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,21 +1,28 @@
from setuptools import setup

try:
from pypandoc import convert
read_md = lambda f: convert(f, 'rst')
except ImportError:
print("pypandoc module not found, could not convert Markdown to RST")
read_md = lambda f: open(f, 'r').read()

setup(
name='buoyant',

version='0.2.1',
version='0.2.2',

description='buoy data from the NOAA',
description="Wrapper for the NOAA National Data Buoy Center",

long_description="Wrapper for NOAA National Data Buoy Center",
long_description=read_md('readme.md'),

url='https://github.com/fitnr/buoyant',

author='Neil Freeman',

author_email='[email protected]',

license='All rights reserved',
license='GPL',

packages=['buoyant'],

Expand All @@ -24,4 +31,13 @@
'requests>=2.4.1'
],

classifiers=[
'License :: OSI Approved :: GNU General Public License v3 (GPLv3)',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Scientific/Engineering :: Atmospheric Science',
'Intended Audience :: Science/Research',
],
)

0 comments on commit 551c969

Please sign in to comment.