Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
probot-metadata
Advanced tools
A Probot extension to store metadata on Issues and Pull Requests.
const metadata = require('probot-metadata');
// where `context` is a Probot `Context`
await metadata(context).set(key, value)
const value = await metadata(context).get(key)
const metadata = require('probot-metadata');
module.exports = robot => {
robot.on('issue_comment.created', async context => {
match = context.payload.comment.body.match('/snooze (.*)')
if(match) {
metadata(context).set('snooze', match[1])
}
})
}
This extension is what you might call "a hack". GitHub doesn't have an API for storing metadata on Issues and Pull Requests, but it does have rather large comment fields. GitHub renders the comments as Markdown and will strip any unsupported HTML (including HTML comments like <!-- I can put whatever I want here -->
), but still serves up the raw comment body through the API. This extension takes advantage of this "feature" to store JSON values on Issues and Pull Requests as HTML comments.
It will update the body of the original post and append an HTML comment with JSON values for each key. For example:
This is the body of the original post
<!-- probot = {"json": "here"} -->
FAQs
A Probot extension to store metadata on Issues and Pull Requests
The npm package probot-metadata receives a total of 24 weekly downloads. As such, probot-metadata popularity was classified as not popular.
We found that probot-metadata demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.