File tree Expand file tree Collapse file tree 3 files changed +37
-1
lines changed Expand file tree Collapse file tree 3 files changed +37
-1
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ script:
1515 # - pytest
1616
1717 # smoke tests
18+ # - make test # TODO: make it use python3 by default
1819 - python tests/test_yapf_format.py
1920 - python tests/test_pydocstyle.py
2021 - python tests/test_mnist_simple.py
Original file line number Diff line number Diff line change @@ -10,4 +10,10 @@ The following tools are used to ensure that your commits can pass through the CI
1010* [ isort] ( https://github.com/timothycrosley/isort ) (sort imports), optional
1111* [ autoflake] ( https://github.com/myint/autoflake ) (remove unused imports), optional
1212
13- Please apply these tools in the changed files before submitting your PR.
13+ You can simply run
14+
15+ ```
16+ make format
17+ ```
18+
19+ to apply those tools before submitting your PR.
Original file line number Diff line number Diff line change 1+ default :
2+ @echo " Usage:"
3+ @echo " \tmake lint # run pylint"
4+ @echo " \tmake format # run yapf, autoflake and isort"
5+ @echo " \tmake install3 # install tensorlayer in current workspace with pip3"
6+
7+ lint :
8+ pylint example/* .py
9+ pylint tensorlayer
10+
11+ test :
12+ python tests/test_yapf_format.py
13+ python tests/test_pydocstyle.py
14+ python tests/test_mnist_simple.py
15+
16+ format :
17+ yapf -i example/* .py
18+ yapf -i tensorlayer/* .py
19+ yapf -i tensorlayer/** /* .py
20+
21+ autoflake -i example/*.py
22+ autoflake -i tensorlayer/*.py
23+ autoflake -i tensorlayer/**/*.py
24+
25+ isort -rc example
26+ isort -rc tensorlayer
27+
28+ install3 :
29+ pip3 install -U . --user
You can’t perform that action at this time.
0 commit comments