-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* block isort * block isort * add vscode ext notes * updating instructions (not complete) * in progress * add video test embed * change video image * play icon * video play button * play button * cleanup * cleanup --------- Co-authored-by: Michael Mann <mmann1123@gmail.com>
- Loading branch information
Showing
6 changed files
with
137 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
# Contibuting to Geowombat | ||
|
||
We have two methods for contribution: | ||
|
||
1. Local install | ||
2. Docker-based debugging | ||
|
||
## 1. Local Install | ||
|
||
### Install GeoWombat | ||
|
||
#### Clone the latest repo | ||
|
||
```commandline | ||
git clone https://github.com/jgrss/geowombat.git | ||
``` | ||
|
||
#### Create a virtual environment | ||
|
||
Modify the Python version (i.e., 3.8.15) as needed | ||
|
||
```commandline | ||
pyenv virtualenv 3.8.15 venv.gw | ||
``` | ||
|
||
#### Activate the virtual environment | ||
|
||
```commandline | ||
pyenv activate venv.gw | ||
``` | ||
|
||
#### Install pre-commit | ||
|
||
```commandline | ||
(venv.gw) pip install pre-commit | ||
(venv.gw) pre-commit install | ||
``` | ||
|
||
#### Install GeoWombat | ||
|
||
Install other extras from `setup.cfg` as needed. | ||
|
||
```commandline | ||
(venv.gw) cd geowombat/ | ||
(venv.gw) pip install -e .[tests] | ||
``` | ||
|
||
### Create a new branch for your contribution | ||
|
||
```commandline | ||
(venv.gw) git checkout -b new_branch_name | ||
``` | ||
|
||
### After making changes, run tests | ||
|
||
```commandline | ||
(venv.gw) cd tests/ | ||
(venv.gw) python -m unittest | ||
``` | ||
|
||
## 2. Docker debugging | ||
|
||
### Prerequisites | ||
|
||
- [Visual Studio Code](https://code.visualstudio.com/download) | ||
- [Docker VSCode Extension](https://code.visualstudio.com/docs/containers/overview) | ||
- [Docker Desktop](https://docs.docker.com/desktop/) | ||
|
||
1. Build `geowombat/dockerfiles/gw_docker_debug` by right clicking and hit `Build Image...` | ||
- This will take a long time the first time only | ||
- Give the image a name like `gw_debug`, hit Enter | ||
2. Click on dock extension tab on left panel of vscode | ||
3. Under Images click on `gw_debug` right click on `latest`, hit `Run Interactive` | ||
4. Under Individual Containers, right click on your running `gw_debug` instance, hit `Attach Visual Studio Code` | ||
5. Once opened make sure the `python` and `ipython` vscode extensions are installed in your attached vscode server | ||
6. Go to `geowombat/src/debug_script.py` run top cell. | ||
7. Add code and run `debug cell` | ||
|
||
View Example Video here: [![Debug Docker](https://github.com/jgrss/geowombat/blob/jgrss/features_precommit/data/resume.png?raw=true)](https://youtu.be/hBIE4qmOsgA "Debug Docker") | ||
|
||
### Create a Pull Request | ||
|
||
#### Commit and push changes | ||
|
||
```commandline | ||
git add . | ||
git commit -m 'your commit message' | ||
git push origin new_branch_name | ||
``` | ||
|
||
#### GitHub Pull Request | ||
|
||
1. Go to 'Pull Requests' tab | ||
2. Go to 'New Pull Request' | ||
3. Choose 'base:main' and 'compare:new_branch_name' | ||
4. 'Create pull request' |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters