Skip to content

Commit

Permalink
Merge pull request #54 from hirosassa/poetrize-gh-actions
Browse files Browse the repository at this point in the history
Introduce poetry and github actions
  • Loading branch information
Hi-king authored Mar 4, 2021
2 parents 44a7426 + 1809c26 commit b3274a1
Show file tree
Hide file tree
Showing 9 changed files with 2,160 additions and 52 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: YAPF Formatting Check

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
formatting-check:

name: Formatting Check
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: run YAPF to test if python code is correctly formatted
uses: AlexanderMelde/yapf-action@master
with:
args: --verbose --style=yapf.ini
27 changes: 27 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Publish

on:
push:
tags: '*'

jobs:
deploy:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'
- name: Install dependencies and build
run: |
python -m pip install --upgrade pip
pip install poetry poetry-dynamic-versioning twine
- name: Build and publish
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: |
poetry publish --build --username $TWINE_USERNAME --password $TWINE_PASSWORD
29 changes: 29 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Test

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:

runs-on: ${{ matrix.platform }}
strategy:
matrix:
platform: [ubuntu-latest]
python-version: [3.7]

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install tox tox-gh-actions poetry
- name: Test with tox
run: tox
16 changes: 0 additions & 16 deletions .travis.yml

This file was deleted.

5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# redshells

[![Build Status](https://travis-ci.org/m3dev/redshells.svg)](https://travis-ci.org/m3dev/redshells)
[![Test](https://github.com/m3dev/redshells/actions/workflows/test.yml/badge.svg)](https://github.com/m3dev/redshells/actions/workflows/test.yml)
[![Python Versions](https://img.shields.io/pypi/pyversions/redshells.svg)](https://pypi.org/project/redshells/)
[![](https://img.shields.io/pypi/v/redshells)](https://pypi.org/project/redshells/)
![](https://img.shields.io/pypi/l/redshells)

Machine learning tasks which are used with data pipeline library "luigi" and its wrapper "gokart".
Loading

0 comments on commit b3274a1

Please sign in to comment.