Skip to content

Commit

Permalink
Migrate to Github Actions (#9)
Browse files Browse the repository at this point in the history
  • Loading branch information
spautz committed Feb 27, 2021
1 parent b0ef8b6 commit 482fafb
Show file tree
Hide file tree
Showing 5 changed files with 53 additions and 38 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: CI

on:
push

jobs:
build:
name: Build & test
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [ 10.x, 12.x, 14.x, 15.x ]

steps:
- uses: actions/checkout@v2

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- name: Get Yarn cache directory
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"

- name: Use Yarn cache
uses: actions/cache@v2
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ matrix.node-version }}-${{ hashFiles('**/yarn.lock') }}

- name: Install dependencies
run: yarn install --prefer-offline

- name: Clear local caches
run: yarn clean

- name: Run CI checks
run: yarn all:readonly

- name: Build package
run: yarn build

- name: Report test coverage to coveralls.io
uses: coverallsapp/github-action@v1.1.2
with:
github-token: ${{ github.token }}
11 changes: 0 additions & 11 deletions .travis.yml

This file was deleted.

4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ A minimal, immutable, deep set utility for Javascript objects and arrays.
Inspired by, and based on, [NickGard's tiny-get](https://github.com/NickGard/tiny-get)

[![npm version](https://img.shields.io/npm/v/tiny-immutable-set.svg)](https://www.npmjs.com/package/tiny-immutable-set)
[![build status](https://img.shields.io/travis/com/spautz/tiny-immutable-set.svg)](https://travis-ci.com/spautz/tiny-immutable-set)
[![build status](https://github.com/spautz/tiny-immutable-set/workflows/CI/badge.svg)](https://github.com/spautz/tiny-immutable-set/actions)
[![dependencies status](https://img.shields.io/badge/dependencies-none-green.svg)](https://david-dm.org/spautz/tiny-immutable-set)
[![gzip size](https://img.badgesize.io/https://unpkg.com/tiny-immutable-set@latest/dist/tiny-immutable-set.cjs.production.min.js?compression=gzip)](https://bundlephobia.com/result?p=tiny-immutable-set)
[![test coverage](https://img.shields.io/coveralls/github/spautz/tiny-immutable-set.svg)](https://coveralls.io/github/spautz/tiny-immutable-set)
[![test coverage](https://img.shields.io/coveralls/github/spautz/tiny-immutable-set/main.svg)](https://coveralls.io/github/spautz/tiny-immutable-set?branch=main)

## Usage

Expand Down
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@
"clean": "yon run build:clean && yon run test:clean && rimraf ./node_modules/.cache",
"dev": "yon run format && yon run types && yon run lint",
"dev:readonly": "yon run format:verify && yon run types && yon run lint",
"all": "yon run clean && yon run dev && yon run test:nowatch && yon run build",
"all:readonly": "yon run clean && yon run dev:readonly && yon run test:nowatch",
"all": "yon run clean && yon run dev && yon run test:coverage && yon run build",
"all:readonly": "yon run clean && yon run dev:readonly && yon run test:coverage",
"ci": "yon run clean && yon run dev:readonly && yon run test:report",
"____ INDIVIDUAL COMMANDS ___________________________________________": "",
"build": "tsdx build",
Expand All @@ -74,7 +74,6 @@
"@ngard/tiny-get": "1.2.2",
"@types/jest": "26.0.20",
"@types/node": "14.14.31",
"coveralls": "3.1.0",
"husky": "5.1.1",
"lint-staged": "10.5.4",
"pinst": "2.1.6",
Expand Down
23 changes: 1 addition & 22 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2368,17 +2368,6 @@ cosmiconfig@^7.0.0:
path-type "^4.0.0"
yaml "^1.10.0"

coveralls@3.1.0:
version "3.1.0"
resolved "https://registry.yarnpkg.com/coveralls/-/coveralls-3.1.0.tgz#13c754d5e7a2dd8b44fe5269e21ca394fb4d615b"
integrity sha512-sHxOu2ELzW8/NC1UP5XVLbZDzO4S3VxfFye3XYCznopHy02YjNkHcj5bKaVw2O7hVaBdBjEdQGpie4II1mWhuQ==
dependencies:
js-yaml "^3.13.1"
lcov-parse "^1.0.0"
log-driver "^1.2.7"
minimist "^1.2.5"
request "^2.88.2"

cross-spawn@^6.0.0, cross-spawn@^6.0.5:
version "6.0.5"
resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4"
Expand Down Expand Up @@ -4563,11 +4552,6 @@ language-tags@^1.0.5:
dependencies:
language-subtag-registry "~0.3.2"

lcov-parse@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/lcov-parse/-/lcov-parse-1.0.0.tgz#eb0d46b54111ebc561acb4c408ef9363bdc8f7e0"
integrity sha1-6w1GtUER68VhrLTECO+TY73I9+A=

leven@^3.1.0:
version "3.1.0"
resolved "https://registry.yarnpkg.com/leven/-/leven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2"
Expand Down Expand Up @@ -4713,11 +4697,6 @@ lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.19:
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c"
integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==

log-driver@^1.2.7:
version "1.2.7"
resolved "https://registry.yarnpkg.com/log-driver/-/log-driver-1.2.7.tgz#63b95021f0702fedfa2c9bb0a24e7797d71871d8"
integrity sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==

log-symbols@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-3.0.0.tgz#f3a08516a5dea893336a7dee14d18a1cfdab77c4"
Expand Down Expand Up @@ -5879,7 +5858,7 @@ request-promise-native@^1.0.7:
stealthy-require "^1.1.1"
tough-cookie "^2.3.3"

request@^2.88.0, request@^2.88.2:
request@^2.88.0:
version "2.88.2"
resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3"
integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==
Expand Down

0 comments on commit 482fafb

Please sign in to comment.