Code Monkey home page Code Monkey logo

shrinky's Introduction

shrinky

Introduction

Usage, etc.

Development installation of this project itself

We're installed with pipenv, a handy wrapper around pip and virtualenv. Install that first with pip3 install pipenv. Then run:

PIPENV_VENV_IN_PROJECT=1 pipenv install --python 3.8 --dev

In case you do not have python 3.8 on your machine, install python using pyenv and try the previous command again. See install pyenv below for instructions.

There will be a script you can run like this::

pipenv run shrinky -p /dataset/something.gpkg -r "table_a:2,3,4;table_b:4,3,6"
pipenv run parse_validation_result -r /dataset/validation.json

It runs the main() function in shrinky/scripts.py, adjust that if necessary. The script is configured in setup.py (see entry_points).

In order to get nicely formatted python files without having to spend manual work on it, run the following command periodically:

pipenv run black shrinky

Run the tests regularly. This also checks with pyflakes, black and it reports coverage. Pure luxury:

pipenv run pytest

If you need a new dependency (like requests), add it in setup.py in install_requires. Afterwards, run install again to actually install your dependency:

pipenv install --dev

Releasing

Pipenv installs zest.releaser which allows you to release the package to a git(hub) repo. It has a fullrelease command that asks you a few questions, which you all respond to with <enter>:

pipenv run fullrelease

Install pyenv

We can install pyenv by running the following commands:

sudo apt-get install -y make build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev xz-utils tk-dev libffi-dev liblzma-dev
curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash

Also make sure to put pyenv in your .bashrc or .zshrc as instructed by the previous commands.

Steps to do after generating with cookiecutter

  • Add a new project on https://github.com/PDOK/ with the same name. Set visibility to "public" and do not generate a license or readme.

    Note: "public" means "don't put customer data or sample data with real persons' addresses on github"!

  • Follow the steps you then see (from "git init" to "git push origin master") and your code will be online.

  • Go to https://github.com/PDOK/shrinky/settings/collaboration and add the teams with write access (you might have to ask someone with admin rights to do it).

  • Once you installed with pipenv, add Pipfile.lock to git: git add Pipfile.lock and commit it to your repo.

  • Update this readme. Use markdown as the format.

  • Ask Roel for a review.

  • Remove this section as you've done it all :-)

shrinky's People

Contributors

roelvandenberg avatar botenvouwer avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.