You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

154 lines
4.4 KiB
YAML

5 years ago
#
# Author: Hari Sekhon
# Date: Tue Feb 4 09:53:28 2020 +0000
#
5 years ago
# vim:ts=2:sts=2:sw=2:et
5 years ago
#
# https://github.com/harisekhon/bash-tools
#
# If you're using my code you're welcome to connect with me on LinkedIn and optionally send me feedback
#
# https://www.linkedin.com/in/harisekhon
#
5 years ago
# MarketPlace: https://github.com/marketplace?type=actions
5 years ago
name: CI Ubuntu
5 years ago
#env:
# DEBUG: 1
5 years ago
on: # [push]
push:
branches:
- master
schedule:
# * is a special character in YAML so you have to quote this string
- cron: '0 10 30 * *'
5 years ago
jobs:
build:
5 years ago
#name: build
timeout-minutes: 10
5 years ago
#runs-on: ubuntu-latest
5 years ago
5 years ago
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, ubuntu-16.04]
5 years ago
# node: [6, 8, 10]
5 years ago
steps:
5 years ago
- uses: actions/checkout@v2
- uses: actions/cache@v1
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-bash-tools # ${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- uses: actions/cache@v1
with:
path: ~/.cpanm
key: ${{ runner.os }}-cpanm-bash-tools # ${{ hashFiles('**/cpan-requirements.txt') }}
restore-keys: |
${{ runner.os }}-cpanm-
- name: build
run: make
- name: test
run: make test
#- name: Run a multi-line script
# run: |
# echo Add other actions to build,
# echo test, and deploy your project.
5 years ago
5 years ago
# ============================================================================
# https://github.com/actions/cache
# ============================================================================
# Python
# - uses: actions/cache@v1
# if: startsWith(runner.os, 'Linux')
# with:
# path: ~/.cache/pip
# key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
# restore-keys: |
# ${{ runner.os }}-pip-
5 years ago
#
# - uses: actions/cache@v1
# if: startsWith(runner.os, 'macOS')
# with:
# path: ~/Library/Caches/pip
# key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
# restore-keys: |
# ${{ runner.os }}-pip-
5 years ago
# ============================================================================
# Perl
# - uses: actions/cache@v1
# with:
# path: ~/.cpanm
# key: ${{ runner.os }}-cpanm-${{ hashFiles('**/cpan-requirements.txt') }}
# restore-keys: |
# ${{ runner.os }}-cpanm-
# ============================================================================
5 years ago
# Go
# - uses: actions/cache@v1
# with:
# path: ~/go/pkg/mod
# key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
# restore-keys: |
# ${{ runner.os }}-go-
5 years ago
# ============================================================================
5 years ago
# Java / Maven
# - uses: actions/cache@v1
# name: Maven Cache
# with:
# path: ~/.m2/repository
# key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
# restore-keys: |
# ${{ runner.os }}-maven-
# - uses: actions/cache@v1
# name: Maven Wrapper
# with:
# path: ~/.m2/wrapper
# key: ${{ runner.os }}-maven-wrapper-${{ hashFiles('**/pom.xml') }}
# restore-keys: |
# ${{ runner.os }}-maven-wrapper-
5 years ago
# ============================================================================
5 years ago
# Scala / SBT
# - uses: actions/cache@v1
# name: SBT Cache
# with:
# path: ~/.sbt
# key: ${{ runner.os }}-sbt-${{ hashFiles('**/build.sbt') }}
# - uses: actions/cache@v1
# name: SBT Ivy Cache
# with:
# path: ~/.ivy2/cache
# key: ${{ runner.os }}-sbt-ivy-cache-${{ hashFiles('**/build.sbt') }}
5 years ago
# ============================================================================
# Gradle
# - uses: actions/cache@v1
# name: Gradle Cache
# with:
# path: ~/.gradle/caches
# key: ${{ runner.os }}-gradle-cache-${{ hashFiles('**/build.gradle') }}
# restore-keys: |
# ${{ runner.os }}-gradle-cache-
# - uses: actions/cache@v1
# name: Gradle Wrapper
# with:
# path: ~/.gradle/wrapper
# key: ${{ runner.os }}-gradle-wrapper-${{ hashFiles('**/build.gradle') }}
# restore-keys: |
# ${{ runner.os }}-gradle-wrapper-
5 years ago
5 years ago
# docker:
# #name: docker
# runs-on:
# - ubuntu-latest
#
# steps:
# - uses: docker://harisekhon/centos-dev
# - name: build & test
# run: make build test