Skip to content
This repository was archived by the owner on Aug 7, 2024. It is now read-only.

Commit cf2869c

Browse files
committed
Merge pull request #191 from kirang89/master
Better bootstrapping
2 parents 719801e + ae56bd6 commit cf2869c

File tree

4 files changed

+52
-3
lines changed

4 files changed

+52
-3
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,6 @@ pip-log.txt
3434

3535
#Mr Developer
3636
.mr.developer.cfg
37+
38+
#Environment
39+
env

Makefile

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
.PHONY: docs test
2+
3+
help:
4+
@echo " env create a development environment using virtualenv"
5+
@echo " deps install dependencies"
6+
@echo " clean remove unwanted stuff"
7+
@echo " lint check style with flake8"
8+
@echo " test run tests"
9+
10+
env:
11+
sudo easy_install pip && \
12+
pip install virtualenv && \
13+
virtualenv env && \
14+
. env/bin/activate && \
15+
make deps
16+
17+
deps:
18+
pip install -r requirements.txt --use-mirrors
19+
20+
clean:
21+
rm -fr build \
22+
rm -fr dist \
23+
find . -name '*.pyc' -exec rm -f {} \
24+
find . -name '*.pyo' -exec rm -f {} \
25+
find . -name '*~' -exec rm -f {}
26+
27+
lint:
28+
flake8 twitter > violations.flake8.txt
29+
30+
test:
31+
python twitter_test.py
32+

README.rst

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,23 @@ Check out the latest development version anonymously with::
3838

3939
$ git clone git://github.com/bear/python-twitter.git
4040
$ cd python-twitter
41+
42+
Setup a virtual environment and install dependencies:
4143

42-
Dependencies
44+
$ make env
45+
46+
Activate the virtual environment created:
47+
48+
$ source env/bin/activate
49+
50+
Run tests:
51+
52+
$ make test
53+
54+
To see other options available, run:
55+
56+
$ make help
4357

44-
* [Requests](http://docs.python-requests.org/en/latest/)
45-
* [Requests OAuthlib](https://requests-oauthlib.readthedocs.org/en/latest/)
4658

4759
=============
4860
Documentation

requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
requests
2+
requests_oauthlib

0 commit comments

Comments
 (0)