Skip to content

Commit

Permalink
Merge c1d8f74 into fea0907
Browse files Browse the repository at this point in the history
  • Loading branch information
oleh-poberezhets committed Jan 23, 2020
2 parents fea0907 + c1d8f74 commit 846fc65
Show file tree
Hide file tree
Showing 5 changed files with 299 additions and 119 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/npm_publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: NPM Release

on:
release:
types: [published, edited]

jobs:
check:
name: Check version and tag
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Get package version
shell: bash
id: package_version
run: |
ver=$(jq .version package.json | sed -e "s/^\"//" -e "s/\"//")
echo "::set-output name=version::$ver"
- name: Compare package version and release tag
if: steps.package_version.outputs.version != github.event.release.tag_name
env:
TAG: "${{ github.event.release.tag_name }}"
PKG_VER: ${{ steps.package_version.outputs.version }}
run: |
echo "Mismatch NPM version $PKG_VER and git tag $TAG"
exit 1
build:
name: Lint and test
needs: check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12
- run: yarn install --frozen-lock-file
- run: yarn lint
- run: yarn tests

publish-npm:
name: Publish to NPM
needs: [check, build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12
registry-url: https://registry.npmjs.org/
- run: yarn install --frozen-lock-file
- run: yarn publish
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
## Changelog

### 2.0.1

- Dependencies was bumped

### 2.0.0

- nvidia-smi runs in the "dmon" mode instead of periodical execs of the nvidia-smi

### 1.1.0

- Add waiting on nvidia-smi response before the next one
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
Helps to monitor Nvidia GPU utilization using nvidia-smi.

[![NPM version](https://img.shields.io/npm/v/nvidia-gpu-monitor.svg)](https://www.npmjs.com/package/nvidia-gpu-monitor)
[![Release Status](https://github.com/LCMApps/nvidia-gpu-monitor/workflows/NPM%20Release/badge.svg)](https://github.com/LCMApps/nvidia-gpu-monitor/releases)
[![Build Status](https://travis-ci.org/LCMApps/nvidia-gpu-monitor.svg?branch=master)](https://travis-ci.org/LCMApps/nvidia-gpu-monitor)
[![Coverage Status](https://coveralls.io/repos/github/LCMApps/nvidia-gpu-monitor/badge.svg?branch=master)](https://coveralls.io/github/LCMApps/nvidia-gpu-monitor?branch=master)

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "nvidia-gpu-monitor",
"version": "2.0.0",
"version": "2.0.1",
"description": "Helps to monitor Nvidia GPU utilization using nvidia-smi",
"main": "index.js",
"scripts": {
Expand Down
Loading

0 comments on commit 846fc65

Please sign in to comment.