Verified Commit 97a9603c authored by Huste, Tobias (FWCC) - 111645's avatar Huste, Tobias (FWCC) - 111645
Browse files

initial project template

parents
Pipeline #8461 failed with stage
in 2 minutes and 8 seconds
.git
*.gitignore
*.mo
*.pyc
*.swp
*.swo
*.~
.dockerignore
Dockerfile
docker-compose.yml
docker-compose-dev.yml
Procfile*
# -*- coding: utf-8 -*-
#
# Copyright (C) 2018 HZDR
#
# This file is part of RODARE.
#
# invenio-gitlab is free software: you can redistribute it
# and/or modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 3 of the License,
# or (at your option) any later version.
#
# invenio-gitlab is distributed in the hope that
# it will be useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Rodare. If not, see <http://www.gnu.org/licenses/>.
root = true
[*]
indent_style = space
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
charset = utf-8
# Python files
[*.py]
indent_size = 4
# isort plugin configuration
known_first_party = invenio_gitlab
multi_line_output = 2
default_section = THIRDPARTY
skip = .eggs
# RST files (used by sphinx)
[*.rst]
indent_size = 4
# CSS, HTML, JS, JSON, YML
[*.{css,html,js,json,yml}]
indent_size = 2
# Matches the exact files either package.json or .travis.yml
[{package.json,.travis.yml}]
indent_size = 2
# Dockerfile
[Dockerfile]
indent_size = 4
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
# Idea software family
.idea/
# C extensions
*.so
# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
*.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
# Translations
*.mo
# Django stuff:
*.log
# Sphinx documentation
docs/_build/
# PyBuilder
target/
# Vim swapfiles
.*.sw?
# -*- coding: utf-8 -*-
#
# Copyright (C) 2018 HZDR
#
# This file is part of RODARE.
#
# invenio-gitlab is free software: you can redistribute it
# and/or modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 3 of the License,
# or (at your option) any later version.
#
# invenio-gitlab is distributed in the hope that
# it will be useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Rodare. If not, see <http://www.gnu.org/licenses/>.
variables:
PIP_CACHE_DIR: $CI_PROJECT_DIR/.pip-cache
cache:
paths:
- $CI_PROJECT_DIR/.pip-cache
before_script:
- curl -sL https://deb.nodesource.com/setup_6.x | bash -
- apt-get -qy install --fix-missing --no-install-recommends nodejs
- pip install --upgrade pip setuptools py
- pip install twine wheel coveralls requirements-builder
- requirements-builder -e all --level=min setup.py > .ci-min-requirements.txt
- requirements-builder -e all --level=pypi setup.py > .ci-pypi-requirements.txt
- requirements-builder -e all --level=dev --req requirements-devel.txt setup.py > .ci-devel-requirements.txt
- pip install -r .ci-$REQUIREMENTS-requirements.txt
- pip install -e .[$EXTRAS]
py3.5-min:
image: python:3.6
variables:
EXTRAS: all
REQUIREMENTS: min
script:
- ./run-tests.sh
py3.5-pypi:
image: python:3.6
variables:
EXTRAS: all
REQUIREMENTS: pypi
script:
- ./run-tests.sh
py3.5-devel:
image: python:3.6
variables:
EXTRAS: all
REQUIREMENTS: devel
script:
- ./run-tests.sh
# -*- coding: utf-8 -*-
#
# Copyright (C) 2018 HZDR
#
# This file is part of RODARE.
#
# invenio-gitlab is free software: you can redistribute it
# and/or modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 3 of the License,
# or (at your option) any later version.
#
# invenio-gitlab is distributed in the hope that
# it will be useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Rodare. If not, see <http://www.gnu.org/licenses/>.
# TODO: Transifex integration
#
# 1) Create message catalog:
# $ python setup.py extract_messages
# $ python setup.py init_catalog -l <lang>
# $ python setup.py compile_catalog
# 2) Ensure project has been created on Transifex under the inveniosoftware
# organisation.
# 3) Install the transifex-client
# $ pip install transifex-client
# 4) Push source (.pot) and translations (.po) to Transifex
# $ tx push -s -t
# 5) Pull translations for a single language from Transifex
# $ tx pull -l <lang>
# 6) Pull translations for all languages from Transifex
# $ tx pull -a
[main]
host = https://www.transifex.com
[invenio.invenio-gitlab-messages]
file_filter = invenio_gitlab/translations/<lang>/LC_MESSAGES/messages.po
source_file = invenio_gitlab/translations/messages.pot
source_lang = en
type = PO
..
Copyright (C) 2018 HZDR
This file is part of RODARE.
invenio-gitlab is free software: you can redistribute it
and/or modify it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3 of the License,
or (at your option) any later version.
invenio-gitlab is distributed in the hope that
it will be useful, but WITHOUT ANY WARRANTY; without even the implied
warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Rodare. If not, see <http://www.gnu.org/licenses/>.
Authors
=======
Module for Invenio that adds GitLab integration.
- HZDR <fwcc@hzdr.de>
..
Copyright (C) 2018 HZDR
This file is part of RODARE.
invenio-gitlab is free software: you can redistribute it
and/or modify it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3 of the License,
or (at your option) any later version.
invenio-gitlab is distributed in the hope that
it will be useful, but WITHOUT ANY WARRANTY; without even the implied
warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Rodare. If not, see <http://www.gnu.org/licenses/>.
Changes
=======
Version 0.1.0 (released TBD)
- Initial public release.
Contributing
============
Contributions are welcome, and they are greatly appreciated! Every
little bit helps, and credit will always be given.
Types of Contributions
----------------------
Report Bugs
~~~~~~~~~~~
Report bugs at https://gitlab.hzdr.de/rodare/invenio-gitlab/issues.
If you are reporting a bug, please include:
* Your operating system name and version.
* Any details about your local setup that might be helpful in troubleshooting.
* Detailed steps to reproduce the bug.
Fix Bugs
~~~~~~~~
Look through the GitLab issues for bugs. Anything tagged with "bug"
is open to whoever wants to implement it.
Implement Features
~~~~~~~~~~~~~~~~~~
Look through the GitLab issues for features. Anything tagged with "feature"
is open to whoever wants to implement it.
Write Documentation
~~~~~~~~~~~~~~~~~~~
Invenio-GitLab could always use more documentation, whether as part of the
official Invenio-GitLab 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://gitlab.hzdr.de/rodare/invenio-gitlab/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.
* Remember that this is a volunteer-driven project, and that contributions
are welcome :)
Get Started!
------------
Ready to contribute? Here's how to set up `invenio-gitlab` for local development.
1. Fork the `rodare/invenio-gitlab` repo on GitLab.
2. Clone your fork locally:
.. code-block:: console
$ git clone git@gitlab.hzdr.de:your_name_here/invenio-gitlab.git
3. Install your local copy into a virtualenv. Assuming you have
virtualenvwrapper installed, this is how you set up your fork for local
development:
.. code-block:: console
$ mkvirtualenv invenio-gitlab
$ cd invenio-gitlab/
$ pip install -e .[all]
4. Create a branch for local development:
.. code-block:: console
$ 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 tests:
.. code-block:: console
$ ./run-tests.sh
The tests will provide you with test coverage and also check PEP8
(code style), PEP257 (documentation), flake8 as well as build the Sphinx
documentation and run doctests.
6. Commit your changes and push your branch to GitLab:
.. code-block:: console
$ git add .
$ git commit -s
-m "component: title without verbs"
-m "* NEW Adds your new feature."
-m "* FIX Fixes an existing issue."
-m "* BETTER Improves and existing feature."
-m "* Changes something that should not be visible in release notes."
$ git push origin name-of-your-bugfix-or-feature
7. Submit a pull request through the GitLab website.
Merge Request Guidelines
------------------------
Before you submit a pull request, check that it meets these guidelines:
1. The pull request should include tests and must not decrease test coverage.
2. If the pull request adds functionality, the docs should be updated. Put
your new functionality into a function with a docstring.
3. The pull request should work for Python 2.7, 3.5 and 3.6.
Installation
============
Invenio-GitLab is on PyPI so all you need is:
.. code-block:: console
$ pip install invenio-gitlab
This diff is collapsed.
# -*- coding: utf-8 -*-
#
# Copyright (C) 2018 HZDR
#
# This file is part of RODARE.
#
# invenio-gitlab is free software: you can redistribute it
# and/or modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 3 of the License,
# or (at your option) any later version.
#
# invenio-gitlab is distributed in the hope that
# it will be useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Rodare. If not, see <http://www.gnu.org/licenses/>.
# TODO: Generate this manifest file by running the following commands:
#
# git init
# git add -A
# pip install -e .[all]
# check-manifest -u
# Check manifest will not automatically add these two files:
include .dockerignore
include .editorconfig
include .tx/config
prune docs/_build
recursive-include invenio_gitlab *.po *.pot *.mo
..
Copyright (C) 2018 HZDR
This file is part of RODARE.
invenio-gitlab is free software: you can redistribute it
and/or modify it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3 of the License,
or (at your option) any later version.
invenio-gitlab is distributed in the hope that
it will be useful, but WITHOUT ANY WARRANTY; without even the implied
warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Rodare. If not, see <http://www.gnu.org/licenses/>.
================
Invenio-GitLab
================
.. image:: https://gitlab.hzdr.de/rodare/invenio-gitlab/badges/master/pipeline.svg
:target: https://gitlab.hzdr.de/rodare/invenio-gitlab/commits/master
:alt: Pipeline status
.. image:: https://gitlab.hzdr.de/rodare/invenio-gitlab/badges/master/coverage.svg
:target: https://gitlab.hzdr.de/rodare/invenio-gitlab/commits/master
:alt: Coverage report
.. image:: https://img.shields.io/badge/License-GPL%20v3-blue.svg
:target: https://www.gnu.org/licenses/gpl-3.0
:alt: GPL-3.0
Module for Invenio that adds GitLab integration.
*This is an experimental developer preview release.*
TODO: Please provide feature overview of module
Further documentation is available on
https://data-management.pages.hzdr.de/invenio-gitlab
=======================
Invenio-GitLab v0.1.0
=======================
Invenio-GitLab v0.1.0 was released on TBD, 2018.
About
-----
Module for Invenio that adds GitLab integration.
*This is an experimental developer preview release.*
What's new
----------
- Initial public release.
Installation
------------
$ pip install invenio-gitlab==0.1.0
Documentation
-------------
http://data-management.pages.hzdr.de/invenio-gitlab
Happy hacking and thanks for flying Invenio-GitLab.
# -*- coding: utf-8 -*-
#
# Copyright (C) 2018 HZDR
#
# This file is part of RODARE.
#
# invenio-gitlab is free software: you can redistribute it
# and/or modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 3 of the License,
# or (at your option) any later version.
#
# invenio-gitlab is distributed in the hope that
# it will be useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Rodare. If not, see <http://www.gnu.org/licenses/>.
# Extraction from Python source files
[python: **.py]
encoding = utf-8
# Extraction from Jinja2 templates
[jinja2: **/templates/**.html]
encoding = utf-8
extensions = jinja2.ext.autoescape, jinja2.ext.with_
# Extraction from JavaScript files
[javascript: **.js]
encoding = utf-8
extract_messages = $._, jQuery._
# Makefile for Sphinx documentation
#
# You can set these variables from the command line.
SPHINXOPTS =
SPHINXBUILD = sphinx-build
PAPER =
BUILDDIR = _build
# User-friendly check for sphinx-build
ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1)
$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/)
endif
# Internal variables.
PAPEROPT_a4 = -D latex_paper_size=a4
PAPEROPT_letter = -D latex_paper_size=letter
ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
# the i18n builder cannot share the environment and doctrees with the others
I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest coverage gettext
help:
@echo "Please use \`make <target>' where <target> is one of"
@echo " html to make standalone HTML files"
@echo " dirhtml to make HTML files named index.html in directories"
@echo " singlehtml to make a single large HTML file"
@echo " pickle to make pickle files"
@echo " json to make JSON files"
@echo " htmlhelp to make HTML files and a HTML help project"
@echo " qthelp to make HTML files and a qthelp project"
@echo " applehelp to make an Apple Help Book"
@echo " devhelp to make HTML files and a Devhelp project"
@echo " epub to make an epub"
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
@echo " latexpdf to make LaTeX files and run them through pdflatex"
@echo " latexpdfja to make LaTeX files and run them through platex/dvipdfmx"
@echo " text to make text files"
@echo " man to make manual pages"
@echo " texinfo to make Texinfo files"
@echo " info to make Texinfo files and run them through makeinfo"
@echo " gettext to make PO message catalogs"
@echo " changes to make an overview of all changed/added/deprecated items"
@echo " xml to make Docutils-native XML files"
@echo " pseudoxml to make pseudoxml-XML files for display purposes"
@echo " linkcheck to check all external links for integrity"
@echo " doctest to run all doctests embedded in the documentation (if enabled)"
@echo " coverage to run coverage check of the documentation (if enabled)"
clean:
rm -rf $(BUILDDIR)/*
html:
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
dirhtml:
$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
singlehtml:
$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
@echo
@echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
pickle:
$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
@echo
@echo "Build finished; now you can process the pickle files."
json:
$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
@echo
@echo "Build finished; now you can process the JSON files."
htmlhelp:
$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
@echo
@echo "Build finished; now you can run HTML Help Workshop with the" \
".hhp project file in $(BUILDDIR)/htmlhelp."
qthelp:
$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
@echo
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
".qhcp project file in $(BUILDDIR)/qthelp, like this:"
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/Invenio-GitLab.qhcp"
@echo "To view the help file:"