From b674ecd9a7d169380e79b6c211eac21e0d4bf7ed Mon Sep 17 00:00:00 2001 From: Ashwini Date: Wed, 27 Sep 2017 04:26:02 +0530 Subject: [PATCH] hacky=>hackr --- README.rst | 32 ++++++++++++++++---------------- {hacky => hackr}/__init__.py | 0 {hacky => hackr}/actions.py | 2 +- {hacky => hackr}/generator.py | 0 {hacky => hackr}/web.py | 0 setup.py | 6 +++--- 6 files changed, 20 insertions(+), 20 deletions(-) rename {hacky => hackr}/__init__.py (100%) rename {hacky => hackr}/actions.py (94%) rename {hacky => hackr}/generator.py (100%) rename {hacky => hackr}/web.py (100%) diff --git a/README.rst b/README.rst index 7ad5081..f152216 100644 --- a/README.rst +++ b/README.rst @@ -1,4 +1,4 @@ -hacky: Unicorn library for Hackathons +hackr: Unicorn library for Hackathons ===================================== An All-in-one library, safe for hackathon consumption. @@ -8,7 +8,7 @@ You can perform each and every task using a single library. Features -------- -hacky currently supports the following features: +hackr currently supports the following features: - Generate random names - Generate random address @@ -20,7 +20,7 @@ hacky currently supports the following features: - Parse data in JSON - Send Emails -hacky officially supports Python 2.7 currently. +hackr officially supports Python 2.7 currently. Usage ----- @@ -28,36 +28,36 @@ Usage Generate Random names - >>> import hacky - >>> a = hacky.generator.names(5) + >>> import hackr + >>> a = hackr.generator.names(5) >>> print a [u'Mr. Thomas Wolf MD', u'Valerie Turner', u'Maria Knight', u'Raymond Shelton', u'Erica Glenn'] Generate Random dates - >>> import hacky - >>> a= hacky.generator.dates(5,1995,2017) + >>> import hackr + >>> a= hackr.generator.dates(5,1995,2017) >>> print a ['1998-08-17 00:00:00', '2007-03-25 00:00:00', '2003-01-27 00:00:00', '2014-10-13 00:00:00', '1995-02-10 00:00:00'] - + Scrape a webpage - >>> import hacky - >>> a= hacky.web.scrape("https://api.github.com/users/ashwini0529") + >>> import hackr + >>> a= hackr.web.scrape("https://api.github.com/users/ashwini0529") Make Web Requests - >>> import hacky + >>> import hackr >>> #If you want the response as a string - >>> a= hacky.web.request("http://httpbin.org/post", method="post", params={'a':'b'}) + >>> a= hackr.web.request("http://httpbin.org/post", method="post", params={'a':'b'}) >>> If you want the response as JSON - >>> a= hacky.web.request("http://httpbin.org/post", method="post", params={'a':'b'}, type="JSON") - + >>> a= hackr.web.request("http://httpbin.org/post", method="post", params={'a':'b'}, type="JSON") + Send Emails - >>> import hacky + >>> import hackr >>> #Enter your GMAIL email address and password in the parameters email, and password. - >>> hacky.actions.email("Hey there", email="foo@bar.com", password="foobar", to="bar@foo.com", subject="Foo Bar") + >>> hackr.actions.email("Hey there", email="foo@bar.com", password="foobar", to="bar@foo.com", subject="Foo Bar") Contribution Guidelines diff --git a/hacky/__init__.py b/hackr/__init__.py similarity index 100% rename from hacky/__init__.py rename to hackr/__init__.py diff --git a/hacky/actions.py b/hackr/actions.py similarity index 94% rename from hacky/actions.py rename to hackr/actions.py index d8d8d3b..6b1bba7 100644 --- a/hacky/actions.py +++ b/hackr/actions.py @@ -6,7 +6,7 @@ ''' A function to send emails using SMTP (GMAIL) -Sample usage: hacky.actions.email("Hey there", +Sample usage: hackr.actions.email("Hey there", email="foo@bar.com", password="foobar", to="bar@foo.com", subject="Foo Bar") ''' diff --git a/hacky/generator.py b/hackr/generator.py similarity index 100% rename from hacky/generator.py rename to hackr/generator.py diff --git a/hacky/web.py b/hackr/web.py similarity index 100% rename from hacky/web.py rename to hackr/web.py diff --git a/setup.py b/setup.py index 2179fed..ff521ce 100644 --- a/setup.py +++ b/setup.py @@ -3,11 +3,11 @@ with open('requirements.txt') as f: required = f.read().splitlines() -setup(name='hacky', +setup(name='hackr', - version='0.1', + version='0.1.1', - url='https://github.com/pytorn/hacky', + url='https://github.com/pytorn/hackr', license='Apache 2.0',