-
Notifications
You must be signed in to change notification settings - Fork 12
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
Open Github issue with contents of web form #13
Comments
@gkiar this means after filling the webform , automatically a github issue will open? |
Ideally, yes! Note: the website is hosted on GitHub pages so I think we can leverage the API exposed to do some things, but I'm not 100% sure this is possible. I'd love either a working prototype or evidence telling me I need to ask for something possible :) |
take a look at mavo.io (it's all github based, and does exactly what's needed for this situation). i would love to see the backend store again become something that's queriable (e.g., json-ld) rather than just a store (json). with mavo, the end-user can contribute without knowing db details, and the db can then be more useful for programmatic things. |
@satra but in mavo,io there is nothing related to creating issues on github. |
@Himanshi-Khandelwal - the way mavo.io works is to fork the repository and send a pull-request to the upstream repo, if the owner does not have write privileges to the repo. effectively it uses github as a database and the PR mechanism for making changes. |
- Added a new form that connects to the Github API on submit and creates a Github issue with the contents of the form. Must add a personal token (line 295) to make it work. - Form checks for required fields and validates URL which should be an absolute URL according to these constraint: https://goo.gl/8JTigJ (AKA it must contain the protocol or it will fail)
I sent a PR but closed it just FYI. I wanted it to count towards my hacktoberfest contribution but forgot it only starts on the 1st 😄 |
Guys, I come from a google search. |
Hi @noraj, thanks for pointing this out! If you're planning to share your solution once you make it, I'd be very interested in seeing it - thanks! :) |
@gkiar If you want to see a solution take a look at the StaticMan doc and demo. Don't expect a solution from me, it seems there is no equivalent to StaticMan and StaticMan is working only for github so I can't use it. The other way to do is to call a remote on a server when the form is submitted, and this script will use the private API of gitlab/github/bitbucket/whatever to open an issue/MR/PR/whatever. But this is a no way because it requires a external server that is breaking the whole idea to use gitlab + gitlab pages + gitlab CI in my case. |
Looks like many years passed after that time, but there is also another solution, you can use Google Apps Script if you want anonymous issues => https://ez34.net/2016/12/publish-anonymous-issues-on-github.html. In that tutorial is mentioned about creating form with Google Forms, but you can natively embed it following https://www.parthkabra.me/html/google-forms-embed, so you will need to create 2 forms, one on website and another at Google and copy action URL from Google. |
Add web form to bottom of
index.html
that, when filed, opens a GitHub issue with the contents of the form.Ideally, the form fields would be something like the following (
*
* indicates required):*
"Entry Category":{Course, Initiative, Data Repository, Organization, Tool}
*
"Entry Name":<string>
*
"Author":<string>
*
"URL":<string>
, ideally tested to be a valid URL<string>
, ideally tested to be a valid URL<string>
, ideally tested to be a valid URL<string>
, ideally tested to be a valid URLThe text was updated successfully, but these errors were encountered: