Validate Pull Requests with a Continuous Integration system #4100

Closed
opened 2025-11-26 20:56:05 -06:00 by GiteaMirror · 18 comments
Owner

Originally created by @m1guelpf on GitHub (Nov 30, 2016).

@Kickball Is there a reason for this repository to avoid using http://danger.systems ?

Originally created by @m1guelpf on GitHub (Nov 30, 2016). @Kickball Is there a reason for this repository to avoid using http://danger.systems ?
GiteaMirror added the feedback neededfixdiscussion labels 2025-11-26 20:56:05 -06:00
Author
Owner

@nodiscc commented on GitHub (Nov 30, 2016):

Link is broken. What do you mean?
Please clarify your question and the issue title.

@nodiscc commented on GitHub (Nov 30, 2016): Link is broken. What do you mean? Please clarify your question and the issue title.
Author
Owner

@nodiscc commented on GitHub (Nov 30, 2016):

Got it. http://danger.systems/ is the correct link. The question about a Continuous Integration system/tests has bee brought up before. See https://github.com/Kickball/awesome-selfhosted/issues/63

@AndyR207 has built a custom scanner which detects invalid entries. I think it's still work in progress, and still not public. I think it would be useful to have a CI system that integrates with Github, so that contributors are immediately aware of problems in their Pull Requests.

There are a few checks available in the Makefile (make checks), and I think a draft of Travis integration has been pushed to a random branch, but I can't find the discussion about it. If you'd like to improve the makefile and/or add Travis tests I'd be glad to merge your changes.

@nodiscc commented on GitHub (Nov 30, 2016): Got it. http://danger.systems/ is the correct link. The question about a Continuous Integration system/tests has bee brought up before. See https://github.com/Kickball/awesome-selfhosted/issues/63 @AndyR207 has built a custom scanner which detects invalid entries. I think it's still work in progress, and still not public. I think it would be useful to have a CI system that integrates with Github, so that contributors are immediately aware of problems in their Pull Requests. There are a few checks available in the [Makefile](https://github.com/Kickball/awesome-selfhosted/blob/master/Makefile) (`make checks`), and I think a draft of Travis integration has been pushed to a random branch, but I can't find the discussion about it. If you'd like to improve the makefile and/or add Travis tests I'd be glad to merge your changes.
Author
Owner

@m1guelpf commented on GitHub (Nov 30, 2016):

To start, @dkhamsing made Awesomebot to check and report broken links directly to pull requests.
Also, you can build custom checks in Ruby and integrate them with Danger to report directly to pull requests.

@m1guelpf commented on GitHub (Nov 30, 2016): To start, @dkhamsing made Awesomebot to check and report broken links directly to pull requests. Also, you can build custom checks in Ruby and integrate them with Danger to report directly to pull requests.
Author
Owner

@nodiscc commented on GitHub (Nov 30, 2016):

The required features for such a CI system would be:

  • Detect broken links
  • Detect outdated projects
  • Detect syntax errors
  • Detect missing language/license
  • Integration with the Pull Request system (warnings)
  • Avoid extra complexity in the repository (a single .travis.yml + Makefile would be ideal)
  • Must run automatically
  • Rely on Free Open Source Software
  • ??

So, mostly enforce contribution guidelines. I think @AndyR207's bot does most of these it just lacks Github PR integration, and a public source release + a running instance. Is there any ETA on this? Else anyone is welcome to propose an implementation (in a Pull Request).

By the way I don't think Danger CI is open source, we should not rely on third party proprietary tools.

@nodiscc commented on GitHub (Nov 30, 2016): The required features for such a CI system would be: - [x] Detect broken links - [ ] Detect outdated projects - [x] Detect syntax errors - [x] Detect missing language/license - [x] Integration with the Pull Request system (warnings) - [ ] Avoid extra complexity in the repository (a single .travis.yml + Makefile would be ideal) - [x] Must run automatically - [x] Rely on Free Open Source Software - [ ] ?? So, mostly enforce contribution guidelines. I think @AndyR207's bot does most of these it just lacks Github PR integration, and a public source release + a running instance. Is there any ETA on this? Else anyone is welcome to propose an implementation (in a Pull Request). By the way I don't think [Danger CI](https://github.com/DangerCI) is open source, we should not rely on third party proprietary tools.
Author
Owner

@n8225 commented on GitHub (Nov 30, 2016):

If you take a look at the https://github.com/Kickball/awesome-selfhosted/tree/addTravis branch, I have started working on it. I hope to put some time into it next week.

@n8225 commented on GitHub (Nov 30, 2016): If you take a look at the https://github.com/Kickball/awesome-selfhosted/tree/addTravis branch, I have started working on it. I hope to put some time into it next week.
Author
Owner

@nodiscc commented on GitHub (Nov 30, 2016):

Great. The list of relevant commits can be found here: https://github.com/Kickball/awesome-selfhosted/compare/addTravis

@nodiscc commented on GitHub (Nov 30, 2016): Great. The list of relevant commits can be found here: https://github.com/Kickball/awesome-selfhosted/compare/addTravis
Author
Owner

@m1guelpf commented on GitHub (Nov 30, 2016):

@nodiscc I will have a look. Anyway, Danger IS open source: https://github.com/danger/danger
Also, opened pull #876 to add title checks adn remember to add a Github API token to enable Danger!
If you want, I can provide one of a bot I use for Danger.

@m1guelpf commented on GitHub (Nov 30, 2016): @nodiscc I will have a look. Anyway, Danger IS open source: https://github.com/danger/danger Also, opened pull #876 to add title checks adn remember to add a Github API token to enable Danger! If you want, I can provide one of a bot I use for Danger.
Author
Owner

@nodiscc commented on GitHub (Nov 30, 2016):

Thanks @m1guelpf I have left the PR for @n8225 to merge.
Also, we may want to get our own API key.

The current tests fail with

The command "if [ $TRAVIS_PULL_REQUEST = 'false' ]; then
  node test.js README.md
  awesome_bot README.md --allow-dupe --allow-redirect --allow-ssl -w notepad.cc,www.invoiceplane.com,proxy.donttrustrobots.nl,demo.phproject.org,dev.webtrees.net
else
  git diff master.. -U0 README.md | grep -Po "(?<=^\+).*" >> temp.md
  node test.js temp.md
  awesome_bot temp.md --allow-redirect'
fi
" exited with 1.

and another error about the missing API key for danger.

Additional checks that are already partly in place:

  • Ensure there is a summary for a pull request
  • Warn when there are merge commits in the diff
  • Awesome bot/check for dead links
@nodiscc commented on GitHub (Nov 30, 2016): Thanks @m1guelpf I have left the PR for @n8225 to merge. Also, we may want to get our own API key. The current tests fail with ``` The command "if [ $TRAVIS_PULL_REQUEST = 'false' ]; then node test.js README.md awesome_bot README.md --allow-dupe --allow-redirect --allow-ssl -w notepad.cc,www.invoiceplane.com,proxy.donttrustrobots.nl,demo.phproject.org,dev.webtrees.net else git diff master.. -U0 README.md | grep -Po "(?<=^\+).*" >> temp.md node test.js temp.md awesome_bot temp.md --allow-redirect' fi " exited with 1. ``` and another error about the missing API key for danger. Additional checks that are already partly in place: - [ ] Ensure there is a summary for a pull request - [ ] Warn when there are merge commits in the diff - [ ] Awesome bot/check for dead links
Author
Owner

@m1guelpf commented on GitHub (Nov 30, 2016):

@nodiscc You can get contribution info from the Github API:
https://developer.github.com/v3/repos/statistics/#get-the-last-year-of-commit-activity-data

@m1guelpf commented on GitHub (Nov 30, 2016): @nodiscc You can get contribution info from the Github API: https://developer.github.com/v3/repos/statistics/#get-the-last-year-of-commit-activity-data
Author
Owner

@m1guelpf commented on GitHub (Dec 1, 2016):

@nodiscc Maybe we should replace the summary check with another check, as we have a pull template that autofills the form. Will search about a way to check if everything is

  • completed

instead of

  • empty
@m1guelpf commented on GitHub (Dec 1, 2016): @nodiscc Maybe we should replace the summary check with another check, as we have a pull template that autofills the form. Will search about a way to check if everything is - [x] completed instead of - [ ] empty
Author
Owner

@n8225 commented on GitHub (Dec 5, 2016):

@AndyR207 @nodiscc @Kickball @m1guelpf
It looks like I've got Travis, Danger, and Awesomebot working reliable. If you guys could create PRs to the addTravis branch to test, it would be greatly appreciated. (Current checks: syntax check, link check, summary not blank, summary boxes all checked, PR title)

@n8225 commented on GitHub (Dec 5, 2016): @AndyR207 @nodiscc @Kickball @m1guelpf It looks like I've got Travis, Danger, and Awesomebot working reliable. If you guys could create PRs to the addTravis branch to test, it would be greatly appreciated. (Current checks: syntax check, link check, summary not blank, summary boxes all checked, PR title)
Author
Owner

@m1guelpf commented on GitHub (Dec 5, 2016):

@n8225 Do you have repo activity test?

@m1guelpf commented on GitHub (Dec 5, 2016): @n8225 Do you have repo activity test?
Author
Owner

@n8225 commented on GitHub (Dec 5, 2016):

@m1guelpf no I don't I've been brainstorming how to implement it.

@n8225 commented on GitHub (Dec 5, 2016): @m1guelpf no I don't I've been brainstorming how to implement it.
Author
Owner

@m1guelpf commented on GitHub (Dec 5, 2016):

@n8225 I would try querying the Github API for contribuiting info

@m1guelpf commented on GitHub (Dec 5, 2016): @n8225 I would try querying the Github API for contribuiting info
Author
Owner

@nodiscc commented on GitHub (Dec 19, 2016):

Thanks @n8225 for your work on this,
Can you document the test.js file a bit? Ideally with comment blocks for each function/...

/*!
 * What the function does
 * \fn function(example, others)
 * \param string example An example parameter
 * \param array others (optional) An array of optional parameters
 * \return string Value returned by this function
 */
@nodiscc commented on GitHub (Dec 19, 2016): Thanks @n8225 for your work on this, Can you document the `test.js` file a bit? Ideally with comment blocks for each function/... ``` /*! * What the function does * \fn function(example, others) * \param string example An example parameter * \param array others (optional) An array of optional parameters * \return string Value returned by this function */ ```
Author
Owner

@m1guelpf commented on GitHub (Dec 19, 2016):

@n8225 Just seen that Danger has Github API usage.
Maybe you could make AwesomeBot check the repo activity...

@m1guelpf commented on GitHub (Dec 19, 2016): @n8225 Just seen that Danger has Github API usage. Maybe you could make AwesomeBot check the repo activity...
Author
Owner

@n8225 commented on GitHub (Dec 22, 2016):

@nodiscc I'll start working on this after the holidays.

@n8225 commented on GitHub (Dec 22, 2016): @nodiscc I'll start working on this after the holidays.
Author
Owner

@nodiscc commented on GitHub (Apr 4, 2017):

Issue mostly resolved: we have automated checks in place to validate syntax and valid links. I will close this and report new issues for the remaining points:

  • Document test.js
  • Detect unmaintained Github repositories in Pull Requests
@nodiscc commented on GitHub (Apr 4, 2017): Issue mostly resolved: we have automated checks in place to validate syntax and valid links. I will close this and report new issues for the remaining points: * Document `test.js` * Detect unmaintained Github repositories in Pull Requests
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/awesome-selfhosted#4100