Update contributing guide

The instructions for setting up virtualenv were out dated.

Signed-off-by: Lubomír Sedlář <lsedlar@redhat.com>
This commit is contained in:
Lubomír Sedlář 2016-09-23 10:19:34 +02:00
parent a042906717
commit 160df7f89a

View File

@ -38,27 +38,20 @@ For running unit tests, these packages are recommended as well:
* python-nose * python-nose
* python-nose-cov * python-nose-cov
Technically, it is possible to work on *Fedora 22*, but setting it up is a While being difficult, it is possible to work on *Pungi* using *virtualenv*.
major headache. Packaged version of *productmd* is too old, and *Pungi* does Install *python-virtualenvwrapper* and use following steps. It will link system
not easily work with *virtualenv*, mostly because many of its Python libraries into the virtual environment and install all packages preferably from
dependencies are not available on PyPI. To get it working, you have to install PyPI or from tarball. You will still need to install all of the non-Python
*kobo* and *productmd* directly from Git and provide symlinks to other packages packages above as they are used by calling an executable. ::
and files in ``$(virtualenvwrapper_get_site_packages_dir)``. You will still
need to install all of the non-Python packages above as they are used by
calling an executable. ::
$ ln -vs "$(deactivate && python -c 'import os, koji; print os.path.dirname(koji.__file__)')" "$(virtualenvwrapper_get_site_packages_dir)" $ mkvirtualenv pungienv
$ ln -vs "$(deactivate && python -c 'import os, rpm; print os.path.dirname(rpm.__file__)')" "$(virtualenvwrapper_get_site_packages_dir)" $ for pkg in koji rpm rpmUtils pykickstart selinux createrepo yum urlgrabber; do ln -vs "$(deactivate && python -c 'import os, '$pkg'; print os.path.dirname('$pkg'.__file__)')" "$(virtualenvwrapper_get_site_packages_dir)"; done
$ ln -vs "$(deactivate && python -c 'import os, rpmUtils; print os.path.dirname(rpmUtils.__file__)')" "$(virtualenvwrapper_get_site_packages_dir)" $ for pkg in _selinux deltarpm _deltarpm krbV sqlitecachec _sqlitecache; do ln -vs "$(deactivate && python -c 'import os, '$pkg'; print '$pkg'.__file__')" "$(virtualenvwrapper_get_site_packages_dir)"; done
$ ln -vs "$(deactivate && python -c 'import os, yum; print os.path.dirname(yum.__file__)')" "$(virtualenvwrapper_get_site_packages_dir)" $ PYCURL_SSL_LIBRARY=nss pip install pycurl --no-binary :all:
$ ln -vs "$(deactivate && python -c 'import os, urlgrabber; print os.path.dirname(urlgrabber.__file__)')" "$(virtualenvwrapper_get_site_packages_dir)" $ pip install https://github.com/release-engineering/kobo/archive/0.5.2.tar.gz
$ ln -vs "$(deactivate && python -c 'import os, krbV; print krbV.__file__')" "$(virtualenvwrapper_get_site_packages_dir)" $ pip install lxml pyopenssl mock sphinx setuptools nose nose-cov productmd jsonschema requests lockfile
$ ln -vs "$(deactivate && python -c 'import os, sqlitecachec; print sqlitecachec.__file__')" "$(virtualenvwrapper_get_site_packages_dir)"
$ ln -vs "$(deactivate && python -c 'import os, _sqlitecache; print _sqlitecache.__file__')" "$(virtualenvwrapper_get_site_packages_dir)" Now you should be able to run all existing tests.
$ PYCURL_SSL_LIBRARY=nss pip install pycurl
$ pip install https://git.fedorahosted.org/cgit/kobo.git/snapshot/kobo-0.4.3.tar.gz#egg=kobo
$ pip install https://github.com/release-engineering/productmd/archive/master.tar.gz#egg=productmd
$ pip install lxml pyopenssl mock sphinx setuptools nose nose-cov
Developing Developing