Skip to content

Commit 1b2ae9b

Browse files
committed
Migrate to github actions
1 parent cf05ba8 commit 1b2ae9b

File tree

3 files changed

+71
-28
lines changed

3 files changed

+71
-28
lines changed

.github/workflows/build.yml

+70
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
on:
2+
push:
3+
branches: [ master ]
4+
pull_request:
5+
branches: [ master ]
6+
7+
8+
jobs:
9+
lint:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
- name: Set up Python
14+
uses: actions/setup-python@v2
15+
with:
16+
python-version: 3.8
17+
18+
- name: Install dependencies
19+
run: |
20+
python -m pip install -U pylint
21+
22+
- name: Install
23+
run: |
24+
python -m pip install .
25+
26+
- name: Run Lint
27+
run: |
28+
pylint --rcfile test/pylint.rc rdl_pygments
29+
30+
#-------------------------------------------------------------------------------
31+
build_sdist:
32+
needs:
33+
- test
34+
- lint
35+
name: Build source distribution
36+
runs-on: ubuntu-latest
37+
steps:
38+
- uses: actions/checkout@v2
39+
40+
- uses: actions/setup-python@v2
41+
name: Install Python
42+
with:
43+
python-version: 3.8
44+
45+
- name: Build sdist
46+
run: python setup.py sdist
47+
48+
- uses: actions/upload-artifact@v2
49+
with:
50+
path: dist/*.tar.gz
51+
52+
#-------------------------------------------------------------------------------
53+
deploy:
54+
needs:
55+
- build_sdist
56+
57+
runs-on: ubuntu-latest
58+
59+
# Only publish when a GitHub Release is created.
60+
if: github.event_name == 'release' && github.event.action == 'published'
61+
steps:
62+
- uses: actions/download-artifact@v2
63+
with:
64+
name: artifact
65+
path: dist
66+
67+
- uses: pypa/gh-action-pypi-publish@master
68+
with:
69+
user: __token__
70+
password: ${{ secrets.pypi_password }}

.travis.yml

-27
This file was deleted.

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1+
![.github/workflows/build.yml](https://github.com/SystemRDL/pygments-systemrdl/workflows/.github/workflows/build.yml/badge.svg)
12
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/pygments-systemrdl.svg)](https://pypi.org/project/pygments-systemrdl)
2-
[![Build Status](https://travis-ci.com/SystemRDL/pygments-systemrdl.svg?branch=master)](https://travis-ci.com/SystemRDL/pygments-systemrdl)
33

44
# pygments-systemrdl
55

0 commit comments

Comments
 (0)