Skip to content

Commit

Permalink
Replaces Travis with GitHub Actions
Browse files Browse the repository at this point in the history
This removes the Travis descriptor and builds using GitHub actions and builds daily
  • Loading branch information
gastaldi committed Nov 12, 2020
1 parent 2c20cc0 commit cb1502e
Show file tree
Hide file tree
Showing 3 changed files with 57 additions and 31 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/deploy.yml
@@ -0,0 +1,26 @@
name: Build and deploy to GitHub Pages

on:
schedule:
- cron: '0 0 * * *'
push:
branches:
- develop
jobs:
github-pages:
runs-on: ubuntu-16.04
steps:
- uses: actions/checkout@v2

# Use GitHub Actions' cache to shorten build times and decrease load on servers
- uses: actions/cache@v1
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gems-
- uses: helaili/jekyll-action@2.0.4
env:
JEKYLL_PAT: ${{ secrets.GITHUB_TOKEN }}

31 changes: 31 additions & 0 deletions .github/workflows/preview.yml
@@ -0,0 +1,31 @@
name: Surge SH Preview

on:
pull_request_target:
# when using teardown: 'true', add default event types + closed event type
types: [opened, synchronize, reopened, closed]

jobs:
preview:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

# Use GitHub Actions' cache to shorten build times and decrease load on servers
- uses: actions/cache@v2.1.3
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gems-
- name: Build Jekyll site
uses: jerryjvl/jekyll-build-action@v1

- uses: afc163/surge-preview@v1
name: Deploy to Surge.sh
with:
surge_token: ${{ secrets.SURGE_TOKEN }}
github_token: ${{ secrets.GITHUB_TOKEN }}
dist: _site
teardown: 'true'
31 changes: 0 additions & 31 deletions .travis.yml

This file was deleted.

0 comments on commit cb1502e

Please sign in to comment.