Skip to content

Commit

Permalink
fix: strf-9257 Added check if theme version exists (#745)
Browse files Browse the repository at this point in the history
  • Loading branch information
jairo-bc authored Aug 17, 2021
1 parent e25dec1 commit a520a55
Show file tree
Hide file tree
Showing 4 changed files with 380 additions and 188 deletions.
6 changes: 3 additions & 3 deletions bin/stencil-release.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
#!/usr/bin/env node

require('colors');
const release = require('../lib/release/release');
const StencilRelease = require('../lib/release/release');
const { PACKAGE_INFO } = require('../constants');
const program = require('../lib/commander');
const { checkNodeVersion } = require('../lib/cliCommon');
const { printCliResultErrorAndExit } = require('../lib/cliCommon');

program.version(PACKAGE_INFO.version).parse(process.argv);

checkNodeVersion();

release();
new StencilRelease().run().catch(printCliResultErrorAndExit);
3 changes: 1 addition & 2 deletions lib/release/questions.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@ const dateFormatOptions = {
day: '2-digit',
};

async function askQuestions(themeConfig, githubToken, remotes) {
async function askQuestions(currentVersion, githubToken, remotes) {
const remoteChoices = remotes.map((remote) => {
return { value: remote, name: `${remote.name}: ${remote.url}` };
});

const currentVersion = await themeConfig.getVersion();
const nextPatchVersion = semver.inc(currentVersion, 'patch');
const nextMinorVersion = semver.inc(currentVersion, 'minor');
const nextMajorVersion = semver.inc(currentVersion, 'major');
Expand Down
Loading

0 comments on commit a520a55

Please sign in to comment.