Skip to content

Commit

Permalink
chore(ci): set up semantic release
Browse files Browse the repository at this point in the history
  • Loading branch information
kenany committed Aug 25, 2020
1 parent 18f7674 commit 0c276c3
Show file tree
Hide file tree
Showing 9 changed files with 85 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1 @@
* text=auto
* text=auto eol=lf
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: 2
updates:
- package-ecosystem: github-actions
directory: /
schedule:
interval: daily
labels:
- ci
27 changes: 27 additions & 0 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: nodejs
on: [pull_request, push]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version: [10, 12, 14]
os: [ubuntu-latest, windows-latest, macOS-latest]
steps:
- name: Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2.1.1
with:
node-version: ${{ matrix.node-version }}
- name: Update npm
run: |
npm install -g npm
npm --version
- uses: actions/checkout@v2.3.2
- name: Install dependencies
uses: bahmutov/npm-install@v1.4.3
with:
useLockFile: false
- name: npm ls
run: npm ls
- name: Test
run: npm test
28 changes: 28 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: release
on:
push:
branches:
- master
jobs:
release:
name: release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.3.2
- name: Node.js
uses: actions/setup-node@v2.1.1
with:
node-version: 12
- name: Update npm
run: |
npm install -g npm
npm --version
- name: Install dependencies
uses: bahmutov/npm-install@v1.4.3
with:
useLockFile: false
- name: Release
run: npm run release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
package-lock = false
12 changes: 12 additions & 0 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
"@semantic-release/github",
"@semantic-release/npm",
"@semantic-release/git"
],
"preset": "conventionalcommits",
"tagFormat": "${version}"
}
7 changes: 0 additions & 7 deletions .travis.yml

This file was deleted.

3 changes: 0 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
# get-random-values

[![Build Status](https://img.shields.io/travis/KenanY/get-random-values.svg)](https://travis-ci.org/KenanY/get-random-values)
[![Dependency Status](https://img.shields.io/gemnasium/KenanY/get-random-values.svg)](https://gemnasium.com/KenanY/get-random-values)

`window.crypto.getRandomValues` or `window.msCrypto.getRandomValues` or
`require('crypto').randomBytes` or an _Error_.

Expand Down
8 changes: 8 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,25 @@
"directories": {
"test": "test"
},
"engines": {
"node": "10 || 12 || >=14"
},
"scripts": {
"release": "semantic-release",
"test": "tape test/*.js"
},
"dependencies": {
"global": "^4.4.0"
},
"devDependencies": {
"@kenan/renovate-config": "1.4.0",
"@semantic-release/changelog": "5.0.1",
"@semantic-release/git": "9.0.0",
"conventional-changelog-conventionalcommits": "4.4.0",
"is-browser": "2.1.0",
"lodash.foreach": "4.5.0",
"lodash.isfunction": "3.0.9",
"semantic-release": "17.1.1",
"tape": "5.0.1"
},
"browser": {
Expand Down

0 comments on commit 0c276c3

Please sign in to comment.