Skip to content

Commit

Permalink
chore: upgrade dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
Andreas Richter committed Feb 2, 2020
1 parent 29c7a05 commit 005c83d
Show file tree
Hide file tree
Showing 12 changed files with 1,293 additions and 744 deletions.
2 changes: 1 addition & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"extends": "groupon/node6"
"extends": "groupon"
}
2 changes: 2 additions & 0 deletions bin/nlm.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env node

'use strict';

require('../lib/cli.js');
2 changes: 1 addition & 1 deletion lib/git/ensure-tag.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ const fs = require('fs');
const run = require('../run');

function fetchTag(cwd, tag) {
return run('git', ['fetch', 'origin', 'tag', tag], { cwd: cwd });
return run('git', ['fetch', 'origin', 'tag', tag], { cwd });
}

/**
Expand Down
10 changes: 5 additions & 5 deletions lib/github/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ Github.prototype.registerEndpoints({
return {
commits: function commits(pullId) {
return request('/repos/{owner}/{repo}/pulls/{pullId}/commits', {
pathParams: { pullId: pullId },
pathParams: { pullId },
}).json();
},
get: function get(pullId) {
return request('/repos/{owner}/{repo}/pulls/{pullId}', {
pathParams: { pullId: pullId },
pathParams: { pullId },
}).json();
},
};
Expand All @@ -72,13 +72,13 @@ Github.prototype.registerEndpoints({
},
listByIssue: function listByIssue(issueId) {
return request('/repos/{owner}/{repo}/issues/{issueId}/labels', {
pathParams: { issueId: issueId },
pathParams: { issueId },
}).json();
},
setForIssue: function setForIssue(issueId, labels) {
return request('/repos/{owner}/{repo}/issues/{issueId}/labels', {
method: 'PUT',
pathParams: { issueId: issueId },
pathParams: { issueId },
json: labels,
});
},
Expand All @@ -100,7 +100,7 @@ Github.prototype.registerEndpoints({
return {
get: function get(tag) {
return request('/repos/{owner}/{repo}/git/refs/tags/{tag}', {
pathParams: { tag: tag },
pathParams: { tag },
}).json();
},
};
Expand Down
2 changes: 1 addition & 1 deletion lib/license/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ function collectFiles(cwd, whitelist, optionalExclude) {
return globAsync(`${directory}/**/*.{js,coffee}`, {
ignore: exclude,
nodir: true,
cwd: cwd,
cwd,
root: cwd, // so /lib works as "expected"
});
}
Expand Down
12 changes: 6 additions & 6 deletions lib/steps/changelog.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,11 @@ function extractBreakingChanges(commit) {
if (!commit.notes || !commit.notes.length) {
return [];
}
return commit.notes.filter(n => n.title === 'BREAKING CHANGE').map(note => {
return { text: note.text, commit: commit };
});
return commit.notes
.filter(n => n.title === 'BREAKING CHANGE')
.map(note => {
return { text: note.text, commit };
});
}

function removeInvalidPRs(prs) {
Expand Down Expand Up @@ -152,9 +154,7 @@ const generateChangeLog = co.wrap(function*(cwd, pkg, options) {
return ` - ${line}`;
});

const titleLine = `${pr.title} - **[@${pr.author.name}](${
pr.author.href
})** [#${pr.pullId}](${pr.href})`;
const titleLine = `${pr.title} - **[@${pr.author.name}](${pr.author.href})** [#${pr.pullId}](${pr.href})`;

return [titleLine].concat(changes).join('\n');
}
Expand Down
2 changes: 1 addition & 1 deletion lib/steps/github-release.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function createGithubRelease(cwd, pkg, options) {
const release = {
tag_name: name,
target_commitish: options.versionCommitSha,
name: name,
name,
body: options.changelog,
};
return github.releases.create(release);
Expand Down
4 changes: 1 addition & 3 deletions lib/steps/pending-changes.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,7 @@ function normalizeReferences(meta, commit) {
function normalizeInternalReference(ref) {
ref.owner = ref.owner || meta.username;
ref.repository = ref.repository || meta.repository;
ref.href = `${meta.htmlBase}/${ref.owner}/${ref.repository}/issues/${
ref.issue
}`;
ref.href = `${meta.htmlBase}/${ref.owner}/${ref.repository}/issues/${ref.issue}`;

if (ref.owner === meta.username && ref.repository === meta.repository) {
ref.prefix = '#';
Expand Down
8 changes: 3 additions & 5 deletions lib/steps/version-commit.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ function addFiles(cwd, files) {

function commit(cwd, message) {
return run('git', ['commit', '-m', message], {
cwd: cwd,
cwd,
env: Object.assign({}, process.env, {
GIT_AUTHOR_NAME: NLM_GIT_NAME,
GIT_AUTHOR_EMAIL: NLM_GIT_EMAIL,
Expand All @@ -57,7 +57,7 @@ function commit(cwd, message) {
}

function getHEAD(cwd) {
return run('git', ['rev-parse', 'HEAD'], { cwd: cwd });
return run('git', ['rev-parse', 'HEAD'], { cwd });
}

function updatePackageLockVersion(cwd, version, files) {
Expand Down Expand Up @@ -90,9 +90,7 @@ function createVersionCommit(cwd, pkg, options) {
}
changeLogContent = '';
}
changeLogContent = `### ${options.nextVersion}\n\n${
options.changelog
}${changeLogContent}`;
changeLogContent = `### ${options.nextVersion}\n\n${options.changelog}${changeLogContent}`;
fs.writeFileSync(changeLogFile, `${changeLogContent.trim()}\n`);

const packageJsonFile = path.join(cwd, 'package.json');
Expand Down
Loading

0 comments on commit 005c83d

Please sign in to comment.