Skip to content

Commit d8f87ff

Browse files
authored
Merge pull request #369 from phadej/ghc-8.8.1
Add GHC-8.8 job
2 parents 02c9f72 + d293582 commit d8f87ff

File tree

3 files changed

+69
-49
lines changed

3 files changed

+69
-49
lines changed

.travis.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ before_cache:
2929
- rm -rfv $CABALHOME/packages/head.hackage
3030
matrix:
3131
include:
32+
- compiler: ghc-8.8.1
33+
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.8.1","cabal-install-3.0"]}}
34+
env: GHCHEAD=true
3235
- compiler: ghc-8.6.5
3336
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.6.5","cabal-install-2.4"]}}
3437
- compiler: ghc-8.4.3
@@ -41,6 +44,8 @@ matrix:
4144
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.10.3","cabal-install-2.4"]}}
4245
- compiler: ghc-7.8.4
4346
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.8.4","cabal-install-2.4"]}}
47+
allow_failures:
48+
- compiler: ghc-8.8.1
4449
before_install:
4550
- HC=$(echo "/opt/$CC/bin/ghc" | sed 's/-/\//')
4651
- HCPKG="$HC-pkg"
@@ -93,6 +98,18 @@ install:
9398
echo " prefix: $CABALHOME" >> $CABALHOME/config
9499
echo "repository hackage.haskell.org" >> $CABALHOME/config
95100
echo " url: http://hackage.haskell.org/" >> $CABALHOME/config
101+
- |
102+
if $GHCHEAD; then
103+
echo "allow-newer: $($HCPKG list --simple-output | sed -E 's/([a-zA-Z-]+)-[0-9.]+/*:\1/g')" >> $CABALHOME/config
104+
105+
echo "repository head.hackage" >> $CABALHOME/config
106+
echo " url: http://head.hackage.haskell.org/" >> $CABALHOME/config
107+
echo " secure: True" >> $CABALHOME/config
108+
echo " root-keys: 07c59cb65787dedfaef5bd5f987ceb5f7e5ebf88b904bbd4c5cbdeb2ff71b740" >> $CABALHOME/config
109+
echo " 2e8555dde16ebd8df076f1a8ef13b8f14c66bad8eafefd7d9e37d0ed711821fb" >> $CABALHOME/config
110+
echo " 8f79fd2389ab2967354407ec852cbe73f2e8635793ac446d09461ffb99527f6e" >> $CABALHOME/config
111+
echo " key-threshold: 3" >> $CABALHOME/config
112+
fi
96113
- cat $CABALHOME/config
97114
- rm -fv cabal.project cabal.project.local cabal.project.freeze
98115
- travis_retry ${CABAL} v2-update -v

github.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ copyright:
3030
Copyright 2012-2013 Mike Burns, Copyright 2013-2015 John Wiegley, Copyright 2016-2019 Oleg Grenrus
3131

3232
tested-with:
33-
GHC ==7.8.4 || ==7.10.3 || ==8.0.2 || ==8.2.2 || ==8.4.3 || ==8.6.5
33+
GHC ==7.8.4 || ==7.10.3 || ==8.0.2 || ==8.2.2 || ==8.4.3 || ==8.6.5 || ==8.8.1
3434

3535
extra-source-files:
3636
README.md

src/GitHub/Data/Webhooks.hs

Lines changed: 51 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ data RepoWebhookEvent
7070
| WebhookPullRequestReviewEvent
7171
| WebhookPullRequestReviewCommentEvent
7272
| WebhookPushEvent
73+
| WebhookRegistryPackageEvent
7374
| WebhookReleaseEvent
7475
| WebhookRepositoryEvent
7576
| WebhookRepositoryImportEvent
@@ -131,55 +132,56 @@ instance Binary EditRepoWebhook
131132
-- JSON instances
132133

133134
instance FromJSON RepoWebhookEvent where
134-
parseJSON (String "*") = pure WebhookWildcardEvent
135-
parseJSON (String "check_run") = pure WebhookCheckRunEvent
136-
parseJSON (String "check_suite") = pure WebhookCheckSuiteEvent
137-
parseJSON (String "commit_comment") = pure WebhookCommitCommentEvent
138-
parseJSON (String "content_reference") = pure WebhookContentReferenceEvent
139-
parseJSON (String "create") = pure WebhookCreateEvent
140-
parseJSON (String "delete") = pure WebhookDeleteEvent
141-
parseJSON (String "deploy_key") = pure WebhookDeployKeyEvent
142-
parseJSON (String "deployment") = pure WebhookDeploymentEvent
143-
parseJSON (String "deployment_status") = pure WebhookDeploymentStatusEvent
144-
parseJSON (String "download") = pure WebhookDownloadEvent
145-
parseJSON (String "follow") = pure WebhookFollowEvent
146-
parseJSON (String "fork") = pure WebhookForkEvent
147-
parseJSON (String "fork_apply") = pure WebhookForkApplyEvent
148-
parseJSON (String "github_app_authorization") = pure WebhookGitHubAppAuthorizationEvent
149-
parseJSON (String "gist") = pure WebhookGistEvent
150-
parseJSON (String "gollum") = pure WebhookGollumEvent
151-
parseJSON (String "installation") = pure WebhookInstallationEvent
152-
parseJSON (String "installation_repositories") = pure WebhookInstallationRepositoriesEvent
153-
parseJSON (String "issue_comment") = pure WebhookIssueCommentEvent
154-
parseJSON (String "issues") = pure WebhookIssuesEvent
155-
parseJSON (String "label") = pure WebhookLabelEvent
156-
parseJSON (String "marketplace_purchase") = pure WebhookMarketplacePurchaseEvent
157-
parseJSON (String "member") = pure WebhookMemberEvent
158-
parseJSON (String "membership") = pure WebhookMembershipEvent
159-
parseJSON (String "meta") = pure WebhookMetaEvent
160-
parseJSON (String "milestone") = pure WebhookMilestoneEvent
161-
parseJSON (String "organization") = pure WebhookOrganizationEvent
162-
parseJSON (String "org_block") = pure WebhookOrgBlockEvent
163-
parseJSON (String "page_build") = pure WebhookPageBuildEvent
164-
parseJSON (String "ping") = pure WebhookPingEvent
165-
parseJSON (String "project_card") = pure WebhookProjectCardEvent
166-
parseJSON (String "project_column") = pure WebhookProjectColumnEvent
167-
parseJSON (String "project") = pure WebhookProjectEvent
168-
parseJSON (String "public") = pure WebhookPublicEvent
169-
parseJSON (String "pull_request") = pure WebhookPullRequestEvent
170-
parseJSON (String "pull_request_review") = pure WebhookPullRequestReviewEvent
171-
parseJSON (String "pull_request_review_comment") = pure WebhookPullRequestReviewCommentEvent
172-
parseJSON (String "push") = pure WebhookPushEvent
173-
parseJSON (String "release") = pure WebhookReleaseEvent
174-
parseJSON (String "repository") = pure WebhookRepositoryEvent
175-
parseJSON (String "repository_import") = pure WebhookRepositoryImportEvent
135+
parseJSON (String "*") = pure WebhookWildcardEvent
136+
parseJSON (String "check_run") = pure WebhookCheckRunEvent
137+
parseJSON (String "check_suite") = pure WebhookCheckSuiteEvent
138+
parseJSON (String "commit_comment") = pure WebhookCommitCommentEvent
139+
parseJSON (String "content_reference") = pure WebhookContentReferenceEvent
140+
parseJSON (String "create") = pure WebhookCreateEvent
141+
parseJSON (String "delete") = pure WebhookDeleteEvent
142+
parseJSON (String "deploy_key") = pure WebhookDeployKeyEvent
143+
parseJSON (String "deployment") = pure WebhookDeploymentEvent
144+
parseJSON (String "deployment_status") = pure WebhookDeploymentStatusEvent
145+
parseJSON (String "download") = pure WebhookDownloadEvent
146+
parseJSON (String "follow") = pure WebhookFollowEvent
147+
parseJSON (String "fork") = pure WebhookForkEvent
148+
parseJSON (String "fork_apply") = pure WebhookForkApplyEvent
149+
parseJSON (String "github_app_authorization") = pure WebhookGitHubAppAuthorizationEvent
150+
parseJSON (String "gist") = pure WebhookGistEvent
151+
parseJSON (String "gollum") = pure WebhookGollumEvent
152+
parseJSON (String "installation") = pure WebhookInstallationEvent
153+
parseJSON (String "installation_repositories") = pure WebhookInstallationRepositoriesEvent
154+
parseJSON (String "issue_comment") = pure WebhookIssueCommentEvent
155+
parseJSON (String "issues") = pure WebhookIssuesEvent
156+
parseJSON (String "label") = pure WebhookLabelEvent
157+
parseJSON (String "marketplace_purchase") = pure WebhookMarketplacePurchaseEvent
158+
parseJSON (String "member") = pure WebhookMemberEvent
159+
parseJSON (String "membership") = pure WebhookMembershipEvent
160+
parseJSON (String "meta") = pure WebhookMetaEvent
161+
parseJSON (String "milestone") = pure WebhookMilestoneEvent
162+
parseJSON (String "organization") = pure WebhookOrganizationEvent
163+
parseJSON (String "org_block") = pure WebhookOrgBlockEvent
164+
parseJSON (String "page_build") = pure WebhookPageBuildEvent
165+
parseJSON (String "ping") = pure WebhookPingEvent
166+
parseJSON (String "project_card") = pure WebhookProjectCardEvent
167+
parseJSON (String "project_column") = pure WebhookProjectColumnEvent
168+
parseJSON (String "project") = pure WebhookProjectEvent
169+
parseJSON (String "public") = pure WebhookPublicEvent
170+
parseJSON (String "pull_request") = pure WebhookPullRequestEvent
171+
parseJSON (String "pull_request_review") = pure WebhookPullRequestReviewEvent
172+
parseJSON (String "pull_request_review_comment") = pure WebhookPullRequestReviewCommentEvent
173+
parseJSON (String "push") = pure WebhookPushEvent
174+
parseJSON (String "registry_package") = pure WebhookRegistryPackageEvent
175+
parseJSON (String "release") = pure WebhookReleaseEvent
176+
parseJSON (String "repository") = pure WebhookRepositoryEvent
177+
parseJSON (String "repository_import") = pure WebhookRepositoryImportEvent
176178
parseJSON (String "repository_vulnerability_alert") = pure WebhookRepositoryVulnerabilityAlertEvent
177-
parseJSON (String "security_advisory") = pure WebhookSecurityAdvisoryEvent
178-
parseJSON (String "star") = pure WebhookStarEvent
179-
parseJSON (String "status") = pure WebhookStatusEvent
180-
parseJSON (String "team") = pure WebhookTeamEvent
181-
parseJSON (String "team_add") = pure WebhookTeamAddEvent
182-
parseJSON (String "watch") = pure WebhookWatchEvent
179+
parseJSON (String "security_advisory") = pure WebhookSecurityAdvisoryEvent
180+
parseJSON (String "star") = pure WebhookStarEvent
181+
parseJSON (String "status") = pure WebhookStatusEvent
182+
parseJSON (String "team") = pure WebhookTeamEvent
183+
parseJSON (String "team_add") = pure WebhookTeamAddEvent
184+
parseJSON (String "watch") = pure WebhookWatchEvent
183185
parseJSON _ = fail "Could not build a Webhook event"
184186

185187
instance ToJSON RepoWebhookEvent where
@@ -222,6 +224,7 @@ instance ToJSON RepoWebhookEvent where
222224
toJSON WebhookPullRequestReviewEvent = String "pull_request_review"
223225
toJSON WebhookPullRequestReviewCommentEvent = String "pull_request_review_comment"
224226
toJSON WebhookPushEvent = String "push"
227+
toJSON WebhookRegistryPackageEvent = String "registry_package"
225228
toJSON WebhookReleaseEvent = String "release"
226229
toJSON WebhookRepositoryEvent = String "repository"
227230
toJSON WebhookRepositoryImportEvent = String "repository_import"

0 commit comments

Comments
 (0)