Skip to content

Commit

Permalink
major refactoring; updated docs; formatted with isort & black
Browse files Browse the repository at this point in the history
  • Loading branch information
pedrishi committed Feb 27, 2021
1 parent 4846c68 commit 78248b8
Show file tree
Hide file tree
Showing 1,674 changed files with 579,195 additions and 97,797 deletions.
15 changes: 1 addition & 14 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ jobs:
steps:
- checkout

- restore_cache:
keys:
- v1-dependencies-{{ checksum "/home/circleci/project/Pipfile.lock" }}
- v1-dependencies-

- run:
name: install dependencies
command: |
Expand All @@ -23,17 +18,9 @@ jobs:
sudo apt install gawk libgfortran4 python2
python3.8 -m pip install --user pytest numpy coverage psutil
- save_cache:
paths:
- ".venv"
- "/usr/local/bin"
- "/usr/local/lib/python3.8/site-packages"
- "/home/circleci/.local/share/virtualenvs/"
key: v1-dependencies-{{ checksum "/home/circleci/project/Pipfile.lock" }}

- run:
name: run tests
command: |
set -e
cd pypka/tests/
cd ./tests/
python3.8 -m pytest test.py
21 changes: 21 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# http://editorconfig.org

root = true

[*]
indent_style = space
indent_size = 4
trim_trailing_whitespace = true
insert_final_newline = true
charset = utf-8
end_of_line = lf

[*.bat]
indent_style = tab
end_of_line = crlf

[LICENSE]
insert_final_newline = false

[Makefile]
indent_style = tab
130 changes: 115 additions & 15 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,32 +8,132 @@ LOG*
*eback.xvg
*.prm
P_*.pdb
.nfs*
*.nfs*
TMP.pdb
clean*.pdb
*.pqr
*.sh

__pycache__
.vscode/
pypka/.vscode/
build/
.eggs/
pypKa.egg-info/
pypka/build/
.pytest_cache/
dist/
pypka.egg-info/
pypka/__pycache__/
pypka/build/
pypka/*.pyc
pypka/delphi4py/*.pyc
pypka/delphi4py/*.pyc
pypka/delphi4py/__pycache__/
pypka/delphi4py/readFiles/*f
pypka/delphi4py/rundelphi/*f
pypka/delphi4py/readFiles/__pycache__/
pypka/delphi4py/rundelphi/__pycache__/
pypka/delphi4py/rundelphi/benchmark
pypka/example/test/
pypka/.nfs*
examples/test/

Dockerfile

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# pyenv
.python-version

# celery beat schedule file
celerybeat-schedule

# SageMath parsed files
*.sage.py

# dotenv
.env

# virtualenv
.venv
venv/
ENV/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/

# IDE settings
.vscode/

!pypka/mc/*so
!pypka/delphi4py/*/*.so

Dockerfile
110 changes: 110 additions & 0 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
.. highlight:: shell

============
Contributing
============

Contributions are welcome, and they are greatly appreciated! Every little bit
helps, and credit will always be given.

You can contribute in many ways:

Types of Contributions
----------------------

Report Bugs
~~~~~~~~~~~

Report bugs at https://github.com/mms-fcul/pypka/issues.

If you are reporting a bug, please include:

* Your operating system name and version.
* PypKa's version and parameters used for the calculation
* Origin of the input structure: Protein Data Bank or simulation (please specify the FF)

Fix Bugs
~~~~~~~~

Look through the GitHub issues for bugs. Anything tagged with "bug" and "help
wanted" is open to whoever wants to implement it.

Implement Features
~~~~~~~~~~~~~~~~~~

Look through the GitHub issues for features. Anything tagged with "enhancement"
and "help wanted" is open to whoever wants to implement it.

Write Documentation
~~~~~~~~~~~~~~~~~~~

PypKa could always use more documentation, whether as part of the
official PypKa docs, in docstrings, or even on the web in blog posts,
articles, and such.

Submit Feedback
~~~~~~~~~~~~~~~

The best way to send feedback is to file an issue at https://github.com/mms-fcul/pypka/issues.

If you are proposing a feature:

* Explain in detail how it would work.
* Keep the scope as narrow as possible, to make it easier to implement.

Get Started!
------------

Ready to contribute? Here's how to set up `pypka` for local development.

1. Fork the `pypka` repo on GitHub.
2. Clone your fork locally::

$ git clone git@github.com:your_name_here/pypka.git

3. Install your local copy into a virtualenv. Assuming you have pipenv installed, this is how you set up your fork for local development::
$ cd pypka/
$ pipenv install pypka

4. Create a branch for local development::

$ git checkout -b name-of-your-bugfix-or-feature

Now you can make your changes locally.

5. When you're done making changes, check that your changes pass the tests::

$ make tests

6. Commit your changes and push your branch to GitHub::

$ git add .
$ git commit -m "Your detailed description of your changes."
$ git push origin name-of-your-bugfix-or-feature

7. Submit a pull request through the GitHub website.

Pull Request Guidelines
-----------------------

Before you submit a pull request, check that it meets these guidelines:

1. The pull request should include tests.
2. If the pull request adds functionality, the docs should be updated. Put
your new functionality into a function with a docstring, and add the
feature to the list in README.rst.
3. The pull request should work for Python 3.5, 3.6, 3.7 and 3.8, and for PyPy.


Deploying
---------

A reminder for the maintainers on how to deploy.
Make sure all your changes are committed.
Then run::

$ bump2version patch # possible: major / minor / patch
$ git push
$ git push --tags

20 changes: 12 additions & 8 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,16 +1,20 @@
include LICENSE README.md
include LICENSE
include README.md
include CONTRIBUTING.rst
global-include *.so addHtaut

graft pypka/G54A7
graft pypka/CHARMM36m
graft pypka/pdb2pqr
graft pypka/delphi4py

prune pypka/tests/
prune pypka/docs/
prune pypka/scripts/
prune __pycache__

global-exclude .vscode .circleci
global-exclude *.out .nfs*
exclude .gitignore
global-exclude *.out .nfs* P_*.pdb *frc *.profl *eback.xvg *.prm clean*.pdb *sh
exclude .gitignore

recursive-enclude tests *
recursive-exclude * __pycache__
recursive-exclude * *.py[co]

recursive-include docs *.rst conf.py Makefile make.bat *.jpg *.png *.gif

0 comments on commit 78248b8

Please sign in to comment.