Skip to content

Commit

Permalink
Merge branch 'master' of github.com:nvkelso/map-label-style-manual
Browse files Browse the repository at this point in the history
  • Loading branch information
nvkelso committed Jun 1, 2012
2 parents 1c17b13 + 9e94ab1 commit 39d4df5
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 2 deletions.
2 changes: 2 additions & 0 deletions tools/street_names/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
MANIFEST
dist
22 changes: 22 additions & 0 deletions tools/street_names/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
StreetNames
===========

`StreetNames` provides utility functions for handling street names.

Current version is 0.1.1.

`short_street_name`
------------------

Shorten a long U.S. street name, e.g. "Main Street" to "Main St".

Examples:

short_street_name('Wodehouse Avenue') == 'Wodehouse Ave'
short_street_name('Wodehouse Street North') == 'Wodehouse St N'
short_street_name('South Wodehouse Boulevard') == 'S Wodehouse Blvd'
short_street_name('East Highway') == 'East Hwy'
short_street_name('North Expressway Northeast') == 'North Expwy NE'
short_street_name('Southwest North Lane') == 'SW North Ln'
short_street_name('Street Drive') == 'Street Dr'
short_street_name('Road Street North') == 'Road St N'
2 changes: 1 addition & 1 deletion tools/street_names/StreetNames/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
>>> short_street_name('Road Street North')
'Road St N'
"""
__version__ = '0.1.0'
__version__ = '0.1.1'

_directions = {
'north': 'N', 'northeast': 'NE',
Expand Down
2 changes: 1 addition & 1 deletion tools/street_names/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
description='Utility functions for handling street names.',
author='Michal Migurski',
author_email='[email protected]',
url='https://github.com/nvkelso/map-label-style-manual',
url='https://github.com/nvkelso/map-label-style-manual/tree/master/tools/street_names',
packages=['StreetNames'],
license='BSD')

0 comments on commit 39d4df5

Please sign in to comment.