Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@semantic-release/github

Package Overview
Dependencies
Maintainers
4
Versions
171
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@semantic-release/github - npm Package Compare versions

Comparing version 9.2.0 to 9.2.1

47

lib/publish.js

@@ -57,7 +57,2 @@ import { resolve, basename, extname } from "node:path";

// If discussionCategoryName is not undefined or false
if (discussionCategoryName) {
release.discussion_category_name = discussionCategoryName;
}
const draftReleaseOptions = { ...release, draft: true };

@@ -80,8 +75,18 @@

// add discussion_category_name if discussionCategoryName is not undefined or false
if (discussionCategoryName) {
release.discussion_category_name = discussionCategoryName;
}
const {
data: { html_url: url, id: releaseId },
data: { html_url: url, id: releaseId, discussion_url },
} = await octokit.request("POST /repos/{owner}/{repo}/releases", release);
logger.log("Published GitHub release: %s", url);
return { url, name: RELEASE_NAME, id: releaseId };
if (discussionCategoryName) {
logger.log("Created GitHub release discussion: %s", discussion_url);
}
return { url, name: RELEASE_NAME, id: releaseId, discussion_url };
}

@@ -157,16 +162,28 @@

const patchRelease = {
owner,
repo,
release_id: releaseId,
draft: false,
};
// add discussion_category_name if discussionCategoryName is not undefined or false
if (discussionCategoryName) {
patchRelease.discussion_category_name = discussionCategoryName;
}
const {
data: { html_url: url },
data: { html_url: url, discussion_url },
} = await octokit.request(
"PATCH /repos/{owner}/{repo}/releases/{release_id}",
{
owner,
repo,
release_id: releaseId,
draft: false,
},
patchRelease,
);
logger.log("Published GitHub release: %s", url);
return { url, name: RELEASE_NAME, id: releaseId };
if (discussionCategoryName) {
logger.log("Created GitHub release discussion: %s", discussion_url);
}
return { url, name: RELEASE_NAME, id: releaseId, discussion_url };
}
{
"name": "@semantic-release/github",
"description": "semantic-release plugin to publish a GitHub release and comment on released Pull Requests/Issues",
"version": "9.2.0",
"version": "9.2.1",
"type": "module",

@@ -6,0 +6,0 @@ "author": "Pierre Vanduynslager (https://twitter.com/@pvdlg_)",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc