| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -19,12 +19,7 @@ install: | |||
| 19 | 19 | - pip install coveralls flake8 sphinx | |
| 20 | 20 | ||
| 21 | 21 | # generate some reflog as git-python tests need it (in master) | |
| 22 | - - git tag __testing_point__ | ||
| 23 | - - git checkout master || git checkout -b master | ||
| 24 | - - git reset --hard HEAD~1 | ||
| 25 | - - git reset --hard HEAD~1 | ||
| 26 | - - git reset --hard HEAD~1 | ||
| 27 | - - git reset --hard __testing_point__ | ||
| 22 | + - ./init-tests-after-clone.sh | ||
| 28 | 23 | ||
| 29 | 24 | # as commits are performed with the default user, it needs to be set for travis too | |
| 30 | 25 | - git config --global user.email "travis@ci.com" | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -34,16 +34,29 @@ Both commands will install the required package dependencies. | |||
| 34 | 34 | A distribution package can be obtained for manual installation at: | |
| 35 | 35 | ||
| 36 | 36 | http://pypi.python.org/pypi/GitPython | |
| 37 | + | ||
| 38 | + If you like to clone from source, you can do it like so: | ||
| 39 | + | ||
| 40 | + ```bash | ||
| 41 | + git clone https://github.com/gitpython-developers/GitPython | ||
| 42 | + git submodule update --init --recursive | ||
| 43 | + ./init-tests-after-clone.sh | ||
| 44 | + ``` | ||
| 37 | 45 | ||
| 38 | 46 | ### RUNNING TESTS | |
| 39 | 47 | ||
| 48 | + *Important*: Right after cloning this repository, please be sure to have executed the `init-tests-after-clone.sh` script in the repository root. Otherwise you will encounter test failures. | ||
| 49 | + | ||
| 40 | 50 | The easiest way to run test is by using [tox](https://pypi.python.org/pypi/tox) a wrapper around virtualenv. It will take care of setting up environnements with the proper dependencies installed and execute test commands. To install it simply: | |
| 41 | 51 | ||
| 42 | 52 | pip install tox | |
| 43 | 53 | ||
| 44 | 54 | Then run: | |
| 45 | 55 | ||
| 46 | 56 | tox | |
| 57 | + | ||
| 58 | + | ||
| 59 | + For more fine-grained control, you can use `nose`. | ||
| 47 | 60 | ||
| 48 | 61 | ### Contributions | |
| 49 | 62 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,15 @@ | |||
| 1 | + #!/bin/bash -e | ||
| 2 | + | ||
| 3 | + if [[ -z "$TRAVIS" ]]; then | ||
| 4 | + read -p "This operation will destroy locally modified files. Continue ? [N/y]: " answer | ||
| 5 | + if [[ ! $answer =~ [yY] ]]; then | ||
| 6 | + exit 2 | ||
| 7 | + fi | ||
| 8 | + fi | ||
| 9 | + | ||
| 10 | + git tag __testing_point__ | ||
| 11 | + git checkout master || git checkout -b master | ||
| 12 | + git reset --hard HEAD~1 | ||
| 13 | + git reset --hard HEAD~1 | ||
| 14 | + git reset --hard HEAD~1 | ||
| 15 | + git reset --hard __testing_point__ | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments