Skip to content

Commit

Permalink
[META][CI] Replaces Travis CI by GitHub Actions (#91)
Browse files Browse the repository at this point in the history
  • Loading branch information
HorlogeSkynet authored Nov 21, 2020
1 parent cbff75f commit 1330b61
Show file tree
Hide file tree
Showing 3 changed files with 106 additions and 66 deletions.
103 changes: 103 additions & 0 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
---
name: Integration

on: [push, pull_request]

jobs:
python:
name: Run, lint & test on Python ${{ matrix.python-version }}
if: |
!contains(github.event.head_commit.message, '[skip ci]')
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: [3.4, 3.5, 3.6, 3.7, 3.8, 3.9, pypy3]

steps:
- uses: actions/checkout@v2

- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install required dependencies
run: |
python -m pip install --upgrade pip
pip install pylint stickytape pyinstaller pex
- name: Install module regularly
run: pip install .

- name: Simple module execution
run: |
time archey
time python -m archey
- name: Lint source code against Pylint
run: pylint archey/

- name: Run our test suite
run: |
python setup.py -q test
python -m unittest
- name: Standalone building (with Stickytape)
run: |
stickytape \
--copy-shebang \
--add-python-path . \
--output-file dist/archey \
archey/__main__.py
chmod +x dist/archey
time ./dist/archey
rm dist/archey
# Disabled against Python 3.4 (PyInstaller does not support it since 4.0).
# Disabled against PyPy (see <https://stackoverflow.com/a/22245203>).
- name: Standalone building (with PyInstaller)
if: ${{ matrix.python-version != '3.4' && matrix.python-version != 'pypy3' }}
run: |
pyinstaller \
--distpath dist \
--specpath dist \
--name archey \
--onefile archey/__main__.py \
--log-level WARN
time ./dist/archey
rm dist/archey
- name: Standalone building (with PEX)
run: |
pex \
-o dist/archey \
-m archey \
.
time ./dist/archey
rm dist/archey
shell:
name: Lint packaging shell scripts
if: |
!contains(github.event.head_commit.message, '[skip ci]')
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- run: shellcheck packaging/*

man:
name: Lint manual page
if: |
!contains(github.event.head_commit.message, '[skip ci]')
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- run: sudo apt install -y groff

- run: |
groff -man -Tascii -z archey.1 2&>1 | tee errors
test ! -s errors
63 changes: 0 additions & 63 deletions .travis.yml

This file was deleted.

6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
> Archey is a simple system information tool written in Python
<p align="center">
<!-- GITHUB & TRAVIS CI -->
<!-- GITHUB -->
<a href="https://github.com/HorlogeSkynet/archey4/releases/latest"><img src="https://img.shields.io/github/release/HorlogeSkynet/archey4.svg?style=for-the-badge"></a>
<a href="https://travis-ci.org/HorlogeSkynet/archey4"><img src="https://img.shields.io/travis/HorlogeSkynet/archey4/master.svg?style=for-the-badge"></a>
<a href="https://github.com/HorlogeSkynet/archey4/commits/master"><img src="https://img.shields.io/github/last-commit/HorlogeSkynet/archey4.svg?style=for-the-badge"></a>
<a href="https://github.com/HorlogeSkynet/archey4/actions"><img src="https://img.shields.io/github/workflow/status/HorlogeSkynet/archey4/Integration/master.svg?style=for-the-badge"></a>
<a href="https://github.com/HorlogeSkynet/archey4/commits"><img src="https://img.shields.io/github/last-commit/HorlogeSkynet/archey4.svg?style=for-the-badge"></a>
<br />
<!-- AUR -->
<a href="https://aur.archlinux.org/packages/archey4/"><img src="https://img.shields.io/aur/version/archey4.svg?style=for-the-badge"></a>
Expand Down

0 comments on commit 1330b61

Please sign in to comment.