mirror of
https://github.com/Guake/guake.git
synced 2025-10-26 11:27:13 +00:00
Add upload to test-pipy and pipy (on tags)
Signed-off-by: Gaetan Semet <gaetan@xeberon.net>
This commit is contained in:
parent
986ace8fa4
commit
ffef36b42b
@ -1,33 +1,49 @@
|
||||
# EditorConfig is awesome: http://EditorConfig.org
|
||||
|
||||
# top-most EditorConfig file
|
||||
# EditorConfig helps developers define and maintain consistent
|
||||
# coding styles between different editors and IDEs
|
||||
# https://editorconfig.org
|
||||
root = true
|
||||
|
||||
[*]
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
[*.py]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
tab_width = 4
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
max_line_length = 100
|
||||
|
||||
[*.rst]
|
||||
tab_width = 4
|
||||
[*.{md,rst,txt,md.j2,rst.j2}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.yml]
|
||||
tab_width = 2
|
||||
[*.{ini,toml}]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
[*.yaml]
|
||||
tab_width = 2
|
||||
[*Dockerfile]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
[*.xml]
|
||||
tab_width = 2
|
||||
[*.js]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.glade]
|
||||
tab_width = 2
|
||||
[*.{html,css,html.j2,css.j2}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.{yml,yaml,yaml.j2,yml.j2}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[Makefile]
|
||||
indent_style = tab
|
||||
indent_size = 4
|
||||
|
||||
# The JSON files contain newlines inconsistently
|
||||
[*.json]
|
||||
insert_final_newline = ignore
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*]
|
||||
end_of_line = lf
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
|
||||
94
.github/workflows/ci.yml
vendored
94
.github/workflows/ci.yml
vendored
@ -13,43 +13,57 @@ jobs:
|
||||
python-version: [3.6, 3.7, 3.8, 3.9]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- name: Checkout the current branch
|
||||
run: |
|
||||
echo "BRANCH=$(echo $GITHUB_REF | cut -d'/' -f 3)" >> $GITHUB_ENV
|
||||
git config remote.origin.fetch +refs/heads/*:refs/remotes/origin/*
|
||||
git fetch --unshallow --tags
|
||||
git tag
|
||||
if [[ $(git rev-parse --abbrev-ref HEAD) == "master" ]]; then
|
||||
echo "reattaching HEAD on master"
|
||||
git symbolic-ref --short HEAD || git checkout -b ${GITHUB_ENV}-test $GITHUB_ENV
|
||||
fi
|
||||
|
||||
sudo apt update -q
|
||||
yes | sudo ./scripts/bootstrap-dev-debian.sh
|
||||
./scripts/bootstrap-dev-pip.sh system
|
||||
#sudo apt install --no-install-recommends -y xvfb gir1.2-gtk-3.0 python3-gi python3-gi-cairo gir1.2-wnck-3.0 gobject-introspection libgirepository1.0-dev
|
||||
|
||||
export DISPLAY=:99.0
|
||||
- name: Test with pytest
|
||||
run: |
|
||||
set -e
|
||||
mkdir test-rtd
|
||||
virtualenv test-rtd
|
||||
. ./test-rtd/bin/activate
|
||||
pip install -r requirements-dev.txt
|
||||
rm -rf test-rtd
|
||||
|
||||
# for dev
|
||||
make dev-actions
|
||||
pipenv run pip install pycairo pygobject
|
||||
# check
|
||||
make check
|
||||
make build
|
||||
make test-actions
|
||||
# prepare for deployment
|
||||
make generate-paths
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Get tag
|
||||
id: tag
|
||||
run: echo ::set-output name=tag::${GITHUB_REF#refs/tags/}
|
||||
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Checkout the current branch
|
||||
run: |
|
||||
echo "BRANCH=$(echo $GITHUB_REF | cut -d'/' -f 3)" >> $GITHUB_ENV
|
||||
git config remote.origin.fetch +refs/heads/*:refs/remotes/origin/*
|
||||
git fetch --unshallow --tags
|
||||
git tag
|
||||
if [[ $(git rev-parse --abbrev-ref HEAD) == "master" ]]; then
|
||||
echo "reattaching HEAD on master"
|
||||
git symbolic-ref --short HEAD || git checkout -b ${GITHUB_ENV}-test $GITHUB_ENV
|
||||
fi
|
||||
|
||||
sudo apt update -q
|
||||
yes | sudo ./scripts/bootstrap-dev-debian.sh
|
||||
./scripts/bootstrap-dev-pip.sh system
|
||||
#sudo apt install --no-install-recommends -y xvfb gir1.2-gtk-3.0 python3-gi python3-gi-cairo gir1.2-wnck-3.0 gobject-introspection libgirepository1.0-dev
|
||||
|
||||
export DISPLAY=:99.0
|
||||
|
||||
- name: Test with pytest
|
||||
run: |
|
||||
set -e
|
||||
mkdir test-rtd
|
||||
virtualenv test-rtd
|
||||
. ./test-rtd/bin/activate
|
||||
pip install -r requirements-dev.txt
|
||||
rm -rf test-rtd
|
||||
|
||||
# for dev
|
||||
make dev-actions
|
||||
pipenv run pip install pycairo pygobject
|
||||
# check
|
||||
make check
|
||||
make build
|
||||
make test-actions
|
||||
# prepare for deployment
|
||||
make generate-paths
|
||||
|
||||
- name: Publish distribution 📦 to Test PyPI
|
||||
uses: pypa/gh-action-pypi-publish@master
|
||||
if: github.ref == 'refs/heads/master'
|
||||
with:
|
||||
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
|
||||
repository_url: https://test.pypi.org/legacy/
|
||||
|
||||
77
.github/workflows/release.yml
vendored
Normal file
77
.github/workflows/release.yml
vendored
Normal file
@ -0,0 +1,77 @@
|
||||
# .github/workflows/release.yml
|
||||
|
||||
name: Release
|
||||
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- '**'
|
||||
|
||||
|
||||
jobs:
|
||||
release:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
python-version: [3.6, 3.7, 3.8, 3.9]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Get tag
|
||||
id: tag
|
||||
run: echo ::set-output name=tag::${GITHUB_REF#refs/tags/}
|
||||
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Checkout the current branch
|
||||
run: |
|
||||
echo "BRANCH=$(echo $GITHUB_REF | cut -d'/' -f 3)" >> $GITHUB_ENV
|
||||
git config remote.origin.fetch +refs/heads/*:refs/remotes/origin/*
|
||||
git fetch --unshallow --tags
|
||||
git tag
|
||||
if [[ $(git rev-parse --abbrev-ref HEAD) == "master" ]]; then
|
||||
echo "reattaching HEAD on master"
|
||||
git symbolic-ref --short HEAD || git checkout -b ${GITHUB_ENV}-test $GITHUB_ENV
|
||||
fi
|
||||
|
||||
sudo apt update -q
|
||||
yes | sudo ./scripts/bootstrap-dev-debian.sh
|
||||
./scripts/bootstrap-dev-pip.sh system
|
||||
#sudo apt install --no-install-recommends -y xvfb gir1.2-gtk-3.0 python3-gi python3-gi-cairo gir1.2-wnck-3.0 gobject-introspection libgirepository1.0-dev
|
||||
|
||||
export DISPLAY=:99.0
|
||||
|
||||
- name: Test with pytest
|
||||
run: |
|
||||
set -e
|
||||
mkdir test-rtd
|
||||
virtualenv test-rtd
|
||||
. ./test-rtd/bin/activate
|
||||
pip install -r requirements-dev.txt
|
||||
rm -rf test-rtd
|
||||
|
||||
# for dev
|
||||
make dev-actions
|
||||
pipenv run pip install pycairo pygobject
|
||||
# check
|
||||
make build
|
||||
# prepare for deployment
|
||||
make generate-paths
|
||||
|
||||
- name: Publish distribution 📦 to Test PyPI
|
||||
uses: pypa/gh-action-pypi-publish@master
|
||||
with:
|
||||
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
|
||||
repository_url: https://test.pypi.org/legacy/
|
||||
|
||||
# - name: Publish distribution 📦 to PyPI
|
||||
# if: startsWith(github.ref, 'refs/tags')
|
||||
# uses: pypa/gh-action-pypi-publish@master
|
||||
# with:
|
||||
# password: ${{ secrets.PYPI_API_TOKEN }}
|
||||
Loading…
Reference in New Issue
Block a user