mirror of
https://github.com/verdaccio/verdaccio.git
synced 2025-02-03 23:09:17 -05:00
69d7df20d8
* chore: enable pnp yarn * chore: ignore pnp * fix type issues on run eslint * add missing dependency and fix some errors * fix most of the errors some were just disabled, already fixed in master * add missing jest-config * update jest@26 align with other deps * add missing @babel/register * clean up * use yarn node * use yarn node on release * chore: add husky 6 * chore: add husky 6 * chore: lint-stage * chore: test * chore: add hook git * chore: test * chore: test * update deps * chore: fix commit lint * fix docker run * update git ignore
27 lines
603 B
JavaScript
27 lines
603 B
JavaScript
'use strict';
|
|
|
|
const [, , /* node */ /* file */ tag] = process.argv;
|
|
|
|
const getStdin = require('get-stdin');
|
|
const Octokit = require('@octokit/rest');
|
|
const octokit = new Octokit({
|
|
auth: `token ${process.env.GITHUB_TOKEN}`,
|
|
});
|
|
|
|
const [repoOwner, repoName] = process.env.GITHUB_REPOSITORY.split('/');
|
|
|
|
getStdin()
|
|
.then(changelog =>
|
|
octokit.repos.createRelease({
|
|
owner: repoOwner,
|
|
repo: repoName,
|
|
tag_name: tag,
|
|
body: changelog,
|
|
draft: false,
|
|
})
|
|
)
|
|
.catch(err => {
|
|
// eslint-disable-next-line no-console
|
|
console.error(err);
|
|
process.exit(1);
|
|
});
|