Skip to content

Commit

Permalink
ci: 💚 add github publish to release process and cleanup packages.
Browse files Browse the repository at this point in the history
  • Loading branch information
Pavel910 committed Sep 16, 2018
1 parent d992cd1 commit 97400e7
Showing 1 changed file with 3 additions and 19 deletions.
22 changes: 3 additions & 19 deletions scripts/release.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ require("dotenv").config();
const path = require("path");
const readPkg = require("read-pkg");
const globby = require("globby");
const execa = require("execa");

if (argv.require) {
if (Array.isArray(argv.require)) {
Expand All @@ -23,7 +22,6 @@ const toPublish = [
"webiny-app",
"webiny-app-admin",
"webiny-app-cms",
"webiny-cms-editor",
"webiny-ui",
"webiny-compose",
"webiny-data-extractor",
Expand Down Expand Up @@ -64,11 +62,12 @@ const packages = globby
const config = {
preview: argv.preview || false,
branch: argv.branch || "master",
ci: true,
ci: false,
tagFormat: pkg => pkg.name + "@v${version}",
packages,
plugins: [
wsr.npmVerify(),
wsr.githubVerify(),
wsr.analyzeCommits({
isRelevant: (pkg, commit) => {
if (commit.message.match(/affects: ((?:.+[\n\r]?)+)/gm)) {
Expand All @@ -91,22 +90,7 @@ const config = {
next();
},
wsr.npmPublish(),
// This following plugin is only for Webiny monorepo
async ({ packages, config }, next) => {
if (config.preview) {
return;
}

for (let i = 0; i < packages.length; i++) {
const pkg = packages[i];
if (!pkg.nextRelease || !pkg.nextRelease.gitTag) {
continue;
}

await execa("git", ["tag", pkg.nextRelease.gitTag]);
}
next();
}
wsr.githubPublish()
]
};

Expand Down

0 comments on commit 97400e7

Please sign in to comment.