Commit dd2674a6 authored by BODERE's avatar BODERE
Browse files

add deploy scripts

parent 77e18ead
......@@ -4,6 +4,7 @@ F. PAUL <fpaul@ifremer.fr>
Fabien CADORET <fcadoret@br152-128.ifremer.fr>
Frederic PAUL <fpaul@hancock.ifremer.fr>
MAISSIAT <pierre.maissiat@partenaire-exterieur.ifremer.fr>
PMAISSIA <Pierre.Maissiat@partenaire-exterieur.ifremer.fr>
Pierre MAISSIAT <pmaissia@ananda.ifremer.fr>
Sylvain Herlédan <sylvain.herledan@shadowz.sytes.net>
Thibaut CHARLES <thibaut.charles@ifremer.fr>
......
......@@ -178,7 +178,7 @@ evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / stateme
# Set the output format. Available formats are text, parseable, colorized, json
# and msvs (visual studio). You can also give a reporter class, e.g.
# mypackage.mymodule.MyReporterClass.
output-format=text
output-format=colorized
# Tells whether to display a full report or only the messages.
reports=no
......
#!/usr/bin/env bash
set -Eeuo pipefail
trap "echo ERR trap fired!" ERR
function clean() {
echo "---------------------------------------------------------------"
echo "Clean workspace"
echo "---------------------------------------------------------------"
python setup.py clean --all
find dist -type f -delete
find lib -type d -name "*.egg-info" -exec rm -rf {} +
}
#
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
PROJECT_ROOT_DIR="$(dirname "$DIR")"
echo "Goto $PROJECT_ROOT_DIR"
cd "$PROJECT_ROOT_DIR"
# clean ws
clean
# generate wheel
echo "---------------------------------------------------------------"
echo "Generate wheel"
echo "---------------------------------------------------------------"
python setup.py bdist_wheel
#
echo "---------------------------------------------------------------"
echo "Deploy to binary repository"
echo "---------------------------------------------------------------"
if [[ -z $(find dist -name "*.dev*") ]]; then
echo "Upload to RELEASE"
twine upload --repository nexus-public-release dist/*
else
echo "Upload to SNAPSHOT"
twine upload --repository nexus-public-snapshot dist/*
fi
# clean ws
clean
#!/bin/bash
set -eu
echo "Running pylint..."
{{PYLINT}} -j8 -E lib/
#!/bin/bash
set -Eeuo pipefail
trap "echo ERR trap fired!" ERR
HOOKS_SRC="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
GIT_DIR="$HOOKS_SRC/../../.git"
PYLINT=$(command -v pylint)
echo "Pylint path: $PYLINT"
cp "$HOOKS_SRC/pre-commit" "$GIT_DIR/hooks/"
sed -i "s:{{PYLINT}}:$PYLINT:g" "$GIT_DIR/hooks/pre-commit"
echo "Git hooks setup"
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment