-
-
Notifications
You must be signed in to change notification settings - Fork 42
[DO NOT MERGE] add HackMD integration #92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This PR should allow Node.js groups to manage meeting minutes on [HackMD](https://hackmd.io). Instead of a Google Doc, the script will create a document based on the template on HackMD, and use the resulting URL in the GitHub issue associated with the meeting. To enable this behavior: 1. Put `USE_HACKMD=1` at the top of your group's issue template file (in `templates/`). 2. `process.env` must contain `CMD_CLI_ID=<email>` where `<email>` is a HackMD login 3. `process.env` must contain `CMD_CLI_ID=<password>` where `<password>` is the user's HackMD password Nuts & bolts: - I split `create-node-meeting-artifacts.js` into several different files, because it was difficult to test - The script now either imports `lib/google-docs.js` or `lib/hackmd.js` depending on whether `USE_HACKMD` is present in the template. Both of these export a function `upload` - `lib/create-gh-issue.js` exports a function which returns a callback. `upload` is given this callback, since the issue cannot be created until the minutes document has a URL. - Added [`@hackmd/codimd-cli`](https://npm.im/@hackmd/codimd-cli) - Removed unused [`google-calendar`](https://npm.im/google-calendar)
We need the HackMD API to support:
In addition, we will either need everyone who wants to edit these minutes documents to have a HackMD account, or we'll need to set permissions to "world-writable" at import time on the documents. |
cc @bnb b/c I know he was interested in this. |
and cc @joesepi for the same reason |
I've been wondering about this for a while. Thanks for working on it @boneskull |
repo: meetingProperties.REPO.replace(/"/g, ''), | ||
title: title, | ||
body, | ||
assignee: 'mhdawson', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lol @mhdawson
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah @mhdawson is the only one who can run this script 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure I'm the only one who could, but the setup required is non-trivial to do the first time.
@@ -6,13 +6,12 @@ const child_process = require('child_process'); | |||
const GitHubApi = require("github"); | |||
const ghauth = require('ghauth'); | |||
const parser = require('properties-parser'); | |||
const gcal = require('google-calendar'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does removing the gcal integration remove the auto generation based on google calendar events?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, gcal
was just unused
Great to see progress on this. Let me know when it is ready for review/landing will be great to have another option for editing the minutes. |
I'm going to close this because I don't think it's likely to progress at this point. Please let me know if you think that was the wrong thing to do and feel free to re-open. |
This PR should allow Node.js groups to manage meeting minutes on HackMD. Instead of a Google Doc, the script will create a document based on the template on HackMD, and use the resulting URL in the GitHub issue associated with the meeting.
To enable this behavior:
USE_HACKMD=1
at the top of your group's issue template file (intemplates/
).process.env
must containCMD_CLI_ID=<email>
where<email>
is a HackMD loginprocess.env
must containCMD_CLI_ID=<password>
where<password>
is the user's HackMD passwordNuts & bolts:
create-node-meeting-artifacts.js
into several different files, because it was difficult to testlib/google-docs.js
orlib/hackmd.js
depending on whetherUSE_HACKMD
is present in the template. Both of these export a functionupload
lib/create-gh-issue.js
exports a function which returns a callback.upload
is given this callback, since the issue cannot be created until the minutes document has a URL.@hackmd/codimd-cli
google-calendar