Skip to content
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

Allow for email notifications with GitLab #1

Merged
merged 6 commits into from
Dec 5, 2020
Merged

Commits on Dec 5, 2020

  1. Enable sending email notifications when using GitLab (as opposed to G…

    …itHub).
    
    - Modify handlePR.js to instantiate a generic GitService instead of GitHub.
    - Modify GitHub.js so that a blank (Staticman) version number can resolve to GitHub token authorization (as the version number is not available when instantiating GitHub from handlePR).
    - Modify server.js to provide v3 service-specific "webhook" endpoints. Retain usage of the express-github-webhook module for GitHub.
    - Update tests and add test cases for GitLab.
    - Add new webhook controller.
    Michael Harry Scepaniak committed Dec 5, 2020
    Configuration menu
    Copy the full SHA
    7e02840 View commit details
    Browse the repository at this point in the history
  2. Remove extraneous commas.

    Michael Harry Scepaniak committed Dec 5, 2020
    Configuration menu
    Copy the full SHA
    ef25d7a View commit details
    Browse the repository at this point in the history
  3. Flesh out the (GitLab) webhook handler with webhook event filtering, …

    …error handling, and webhook request authentication.
    
    - Add support in the Staticman JSON configuration for GitLab and GitHub webhook request authentication via "gitlabWebhookSecret" and "githubWebhookSecret" properties.
    - In the handlePR controller, pass real values for the "branch" to the GitFactory.
    - In the handlePR controller, pass a value for "username" to the GitFactory that identifies the repo owner, not the submitter of the merge/pull request.
    - In the handlePR controller, when appropriate, return helpful error messages instead of simply null.
    - In the handlePR controller, fix the "staticman_" source branch test.
    - In the handlePR controller, clean up the analytics events invocations, as the logic is doing more than just deleting the source branch.
    - Improve server.js to silence UnhandledPromiseRejectionWarning messages.
    - Update and add unit tests.
    Michael Harry Scepaniak committed Dec 5, 2020
    Configuration menu
    Copy the full SHA
    f5f52f8 View commit details
    Browse the repository at this point in the history
  4. Code clean-up.

    - Remove commented-out code.
    - Add explicit error handler to allows for overriding the system/express error handler.
    Michael Harry Scepaniak committed Dec 5, 2020
    Configuration menu
    Copy the full SHA
    ad59705 View commit details
    Browse the repository at this point in the history
  5. Remove extraneous whitespace.

    Michael Harry Scepaniak committed Dec 5, 2020
    Configuration menu
    Copy the full SHA
    d400a36 View commit details
    Browse the repository at this point in the history
  6. Improve/fix comment.

    Michael Harry Scepaniak committed Dec 5, 2020
    Configuration menu
    Copy the full SHA
    791e56a View commit details
    Browse the repository at this point in the history