Commit Graph

2733 Commits

Author SHA1 Message Date
Caleb Cartwright
ee97de13f3 refactor(sourceforge): ref. sourceforge and add folder test (#3127) 2019-03-01 21:56:34 +00:00
Paul Melnikow
56e71d7c76 Label all deprecated services as such (#3120)
* Label all deprecated services as such

This will change

service_requests_total{category="other",family="cocoapods",service="cocoapods_apps"} 76

to

service_requests_total{category="other",family="cocoapods",service="deprecated_cocoapods_apps"} 76

* Fix tests
2019-02-28 18:22:28 -06:00
Paul Melnikow
97358c1399 Rewrite [GitHubStars] (#3119)
* Refactor [GithubStars]

* Add test of link array
2019-02-28 18:18:32 -06:00
Henry Poydar
513b69272e Update instructions for self-hosting Shields with Heroku (#3123) 2019-02-28 18:13:44 -06:00
Pierre-Yves B
1f29c22d3d Migrated most service tests to use new expectBadge (#3122) 2019-02-28 21:43:23 +00:00
XhmikosR
4e2d144f97 Fix footer links (#3121)
Fix discord footer link and remove trailing slash from repo URL
2019-02-28 11:55:38 -05:00
Paul Melnikow
b43c9c7c18 Refactor [bitrise] (#3117) 2019-02-27 23:21:11 -05:00
Paul Melnikow
fafb22efee Move "good" badge helpers from lib/ to services/ (#3101)
This moves a few helpers from `lib/` to `services/`:

build-status.js
build-status.spec.js
color-formatters.js
color-formatters.spec.js
contributor-count.js
licenses.js
licenses.spec.js
php-version.js
php-version.spec.js
text-formatters.js
text-formatters.spec.js
version.js
version.spec.js

And one from `lib/` to `core/`:

unhandled-rejection.spec.js

The diff is long, but the changes are straightforward.

Ref #2832
2019-02-27 20:47:46 -05:00
Paul Melnikow
8b2ecaefd1 Remove Heroku buildpack config; allow devDependencies to be pruned (#3115)
The buildpack config doesn't seem to be needed. This would affect review apps, staging, and self-hosting.

Also, devDependencies are installed by default during the build: https://devcenter.heroku.com/changelog-items/1376

By removing `NPM_CONFIG_PRODUCTION=false` we allow these to be pruned so they're kept out of the slug. This also has the advantage of creating a test environment in PRs where missing production dependencies will cause things to break. That'd be a good thing!
2019-02-27 19:08:19 -05:00
Paul Melnikow
dfc95ddd1a Add per-badge metrics for BaseService (#3093)
This picks up #2068 by adding per-badge stats as discussed in #966.

It ensures every service has a unique `name` property. By default this comes from the class name, and is overridden in all the various places where the class names are duplicated. (Some of those don't seem that useful, like the various download interval services, though those need to be refactored down into a single service anyway.) Tests enforce the names are unique. These are the names used by the service-test runner, so it's a good idea to make them unique anyway. (It was sort of strange before that you had to specify `nuget` instead of e.g. `resharper`.)

I've added validation to `deprecatedService` and `redirector`, and required that every `route` has a `base`, even if it's an empty string.

The name is used to generate unique metric labels, generating metrics like these:

```
service_requests_total{category="activity",family="eclipse-marketplace",service="eclipse_marketplace_update"} 2
service_requests_total{category="activity",family="npm",service="npm_collaborators"} 3
service_requests_total{category="activity",family="steam",service="steam_file_release_date"} 2
service_requests_total{category="analysis",family="ansible",service="ansible_galaxy_content_quality_score"} 2
service_requests_total{category="analysis",family="cii-best-practices",service="cii_best_practices_service"} 4
service_requests_total{category="analysis",family="cocoapods",service="cocoapods_docs"} 2
service_requests_total{category="analysis",family="codacy",service="codacy_grade"} 3
service_requests_total{category="analysis",family="coverity",service="coverity_scan"} 2
service_requests_total{category="analysis",family="coverity",service="deprecated_coverity_ondemand"} 2
service_requests_total{category="analysis",family="dependabot",service="dependabot_semver_compatibility"} 3
service_requests_total{category="analysis",family="lgtm",service="lgtm_alerts"} 2
service_requests_total{category="analysis",family="lgtm",service="lgtm_grade"} 3
service_requests_total{category="analysis",family="snyk",service="snyk_vulnerability_git_hub"} 4
service_requests_total{category="analysis",family="snyk",service="snyk_vulnerability_npm"} 5
service_requests_total{category="analysis",family="symfony",service="sensiolabs_i_redirector"} 1
service_requests_total{category="analysis",family="symfony",service="symfony_insight_grade"} 1
service_requests_total{category="build",family="appveyor",service="app_veyor_ci"} 3
service_requests_total{category="build",family="appveyor",service="app_veyor_tests"} 6
service_requests_total{category="build",family="azure-devops",service="azure_dev_ops_build"} 6
service_requests_total{category="build",family="azure-devops",service="azure_dev_ops_release"} 5
service_requests_total{category="build",family="azure-devops",service="azure_dev_ops_tests"} 6
service_requests_total{category="build",family="azure-devops",service="vso_build_redirector"} 2
service_requests_total{category="build",family="azure-devops",service="vso_release_redirector"} 1
service_requests_total{category="build",family="bitbucket",service="bitbucket_pipelines"} 5
service_requests_total{category="build",family="circleci",service="circle_ci"} 5
```

This is predicated on being able to use Prometheus's [`rate()`](https://prometheus.io/docs/prometheus/latest/querying/functions/#rate) function to visualize a counter's rate of change, as mentioned at https://github.com/badges/shields/issues/2068#issuecomment-466696561. Otherwise the stats will be disrupted every time a server restarts.

The metrics only appear on new-style services.
2019-02-27 18:58:59 -05:00
dependabot[bot]
62a89fc834 Bump react from 16.8.2 to 16.8.3 (#3102)
Bumps [react](https://github.com/facebook/react/tree/HEAD/packages/react) from 16.8.2 to 16.8.3.
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v16.8.3/packages/react)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-27 18:42:09 -05:00
dependabot[bot]
c050fc976f Bump babel-preset-gatsby from 0.1.7 to 0.1.8 (#3106)
Bumps babel-preset-gatsby from 0.1.7 to 0.1.8.

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-27 18:25:50 -05:00
dependabot[bot]
f3804a0764 Bump gatsby-plugin-page-creator from 2.0.7 to 2.0.8 (#3108)
Bumps gatsby-plugin-page-creator from 2.0.7 to 2.0.8.

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-27 18:22:32 -05:00
dependabot[bot]
94b150195e Bump mocha-env-reporter from 3.0.0 to 4.0.0 (#3078)
Bumps [mocha-env-reporter](https://github.com/wix/mocha-env-reporter) from 3.0.0 to 4.0.0.
- [Release notes](https://github.com/wix/mocha-env-reporter/releases)
- [Commits](https://github.com/wix/mocha-env-reporter/commits)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-27 18:19:51 -05:00
Paul Melnikow
73d8156f44 Convert some format regexes to patterns (#3109) 2019-02-27 17:52:20 -05:00
Pierre-Yves B
81fbd4ed49 Introduced expectBadge helper (#3097) 2019-02-27 08:02:14 +00:00
Paul Melnikow
e4fe8c0c5f Rewrite [GithubSearch] (#3099) 2019-02-25 15:24:41 -05:00
chris48s
92039e413d add notes to logo docs about brand guidelines (#3088) 2019-02-25 20:02:07 +00:00
chris48s
c6ea546fab use caret for all gh-badges dependencies (#3110) 2019-02-25 19:56:24 +00:00
Paul Melnikow
b14fdd7fd7 Reorganize categories code (#3100)
Seems that the list of categories belongs with the services, while the
support code belongs with base service.

Ref #2832
2019-02-25 14:39:12 -05:00
Paul Melnikow
9fa9785568 Rewrite [GithubRelease] (#3098) 2019-02-25 14:33:52 -05:00
dependabot[bot]
95c11dd7ac Bump gatsby from 2.1.14 to 2.1.17 (#3105)
Bumps [gatsby](https://github.com/gatsbyjs/gatsby) from 2.1.14 to 2.1.17.
- [Release notes](https://github.com/gatsbyjs/gatsby/releases)
- [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/CHANGELOG.md)
- [Commits](https://github.com/gatsbyjs/gatsby/compare/gatsby@2.1.14...gatsby@2.1.17)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-25 19:01:29 +00:00
dependabot[bot]
7217a7e3ba Bump simple-icons from 1.9.20 to 1.9.21 (#3107)
Bumps [simple-icons](https://github.com/simple-icons/simple-icons) from 1.9.20 to 1.9.21.
- [Release notes](https://github.com/simple-icons/simple-icons/releases)
- [Commits](https://github.com/simple-icons/simple-icons/commits)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-25 18:57:24 +00:00
dependabot[bot]
781c7b941e Bump danger from 7.0.13 to 7.0.14 (#3104)
Bumps [danger](https://github.com/danger/danger-js) from 7.0.13 to 7.0.14.
- [Release notes](https://github.com/danger/danger-js/releases)
- [Changelog](https://github.com/danger/danger-js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/danger/danger-js/compare/7.0.13...7.0.14)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-25 18:54:29 +00:00
Paul Melnikow
c7d707363c Refactor [luarocks] (#3094) 2019-02-24 16:11:17 -05:00
Paul Melnikow
f831fba4d4 Rewrite [GitHubLicense] (#3095) 2019-02-24 16:04:24 -05:00
Paul Melnikow
e3d115cf99 Rename maxAge to cacheSeconds (#3090)
Close #3069
2019-02-23 20:33:38 -05:00
chris48s
9ed78867f7 fix [amo] badges (#3083)
This switches to the new mozilla add-ons API.

It's not a completely like-for-like replacement. I was able to replicate the version, users and rating badges but we no longer have total download stats. We've got weekly downloads instead, so I've redirected `/d` to the new `/dw`

closes #3079
2019-02-23 20:11:11 -05:00
Paul Melnikow
8c244c2e40 Fix color overriding for legacy services (#3091)
While I was doing #3090 I realized the work in #3012 did not handle legacy services.

I tested this manually with `/librariesio/release/hex/phoenix.svg?color=blue` and it works.
2019-02-23 19:07:31 -05:00
dependabot[bot]
c3ecde05ee Bump react-dom from 16.8.2 to 16.8.3 (#3075)
Bumps [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom) from 16.8.2 to 16.8.3.
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v16.8.3/packages/react-dom)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-23 15:43:48 -05:00
Paul Melnikow
751af4bb3a Remove unused package (#3087) 2019-02-23 15:40:48 -05:00
Paul Melnikow
a40093d4a1 Named logo should override logoSvg in [endpoint]; also test [static] (#3049)
Fix #2998
2019-02-23 15:37:37 -05:00
Paul Melnikow
09e902fa38 Add frontend prop-type validation for the service definition schema (#3063)
Closes #2702
2019-02-23 15:34:49 -05:00
chris48s
7d1d74cfcf refactor [maven-metadata] service (#3085) 2019-02-23 15:29:46 -05:00
Paul Melnikow
6684f4b566 Remove unused version helper (#3086) 2019-02-23 15:20:34 -05:00
chris48s
912d2018f9 refactor chef [cookbook] service (#3084) 2019-02-23 15:12:13 -05:00
dependabot[bot]
6b7561b150 Bump gatsby from 2.1.13 to 2.1.14 (#3076)
Bumps [gatsby](https://github.com/gatsbyjs/gatsby) from 2.1.13 to 2.1.14.
- [Release notes](https://github.com/gatsbyjs/gatsby/releases)
- [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/CHANGELOG.md)
- [Commits](https://github.com/gatsbyjs/gatsby/compare/gatsby@2.1.13...gatsby@2.1.14)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-22 22:07:17 +00:00
dependabot[bot]
f98484f8e7 Bump danger from 7.0.12 to 7.0.13 (#3070)
Bumps [danger](https://github.com/danger/danger-js) from 7.0.12 to 7.0.13.
- [Release notes](https://github.com/danger/danger-js/releases)
- [Changelog](https://github.com/danger/danger-js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/danger/danger-js/compare/7.0.12...7.0.13)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-22 22:04:39 +00:00
dependabot[bot]
a46df6b347 Bump mocha from 6.0.0 to 6.0.1 (#3077)
Bumps [mocha](https://github.com/mochajs/mocha) from 6.0.0 to 6.0.1.
- [Release notes](https://github.com/mochajs/mocha/releases)
- [Changelog](https://github.com/mochajs/mocha/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mochajs/mocha/compare/v6.0.0...v6.0.1)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-22 10:57:55 -05:00
Paul Melnikow
cd49bda968 Improve coverage in frontend and remove some dead code (#3031) 2019-02-22 00:08:11 -05:00
dependabot[bot]
a9ed1e144e Bump gatsby-plugin-page-creator from 2.0.6 to 2.0.7 (#3060)
Bumps gatsby-plugin-page-creator from 2.0.6 to 2.0.7.

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-22 00:04:55 -05:00
Paul Melnikow
ab18bc0f09 Shorten [endpoint] URL (#3050)
Ref https://github.com/badges/shields/issues/2838#issuecomment-461794344
2019-02-22 00:01:56 -05:00
Paul Melnikow
4bd16f93e8 Sort imports and requires (#3056)
This will definitely save time, and ensure more uniformity.

It moves the `createServiceTester()` calls to a different place from where I'd like them, though I'm happy to have them checked by the linter.

Closes #2701
2019-02-21 22:14:40 -05:00
mbarkhau
f6628e62b7 [QueryStringStatic] service (#3024)
Ref #2673
2019-02-21 21:12:24 -05:00
Paul Melnikow
9e4a8cec09 Consolidate badge URL generation functions (#3032)
This consolidates all the badge URL generation functions into a single place, and updates the rest of the calling code to use it. It renames some things and updates labels to bring the names into alignment with the current API.

Resolve #2027
2019-02-21 21:07:27 -05:00
Danial
f550f0cc4d Update Travis logo, Reduce some duplication (#3047)
Switch Travis to use full-color logo approved at https://github.com/badges/shields/pull/1276#issuecomment-466164851
2019-02-21 20:29:23 -05:00
dependabot[bot]
41fc3bbbf8 Bump icedfrisby from 2.0.0-alpha.3 to 2.0.0-alpha.4 (#3073)
Bumps [icedfrisby](https://github.com/RobertHerhold/IcedFrisby) from 2.0.0-alpha.3 to 2.0.0-alpha.4.
- [Release notes](https://github.com/RobertHerhold/IcedFrisby/releases)
- [Changelog](https://github.com/IcedFrisby/IcedFrisby/blob/master/CHANGELOG.md)
- [Commits](https://github.com/RobertHerhold/IcedFrisby/compare/2.0.0-alpha.3...2.0.0-alpha.4)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-21 00:45:51 -05:00
Paul Melnikow
33aefcfaf8 Minor cleanup related to colorB -> color (#3066)
As `color` is now the canonical, it makes sense to update some of these tests to say `colorB` instead.

Ref #3012
2019-02-20 23:34:22 -05:00
Paul Melnikow
2d7be31b0c Validate query params in BaseService (#3042)
This is a mid-sized PR that adds query param validation to BaseService and updates most of the services which use query param validation to use it. There are a couple minor tweaks I made along the way.

Fix #2676
2019-02-20 22:24:47 -05:00
dependabot[bot]
52a71cb327 Bump gatsby from 2.1.4 to 2.1.13 (#3067)
Bumps [gatsby](https://github.com/gatsbyjs/gatsby) from 2.1.4 to 2.1.13.
- [Release notes](https://github.com/gatsbyjs/gatsby/releases)
- [Changelog](https://github.com/gatsbyjs/gatsby/blob/master/CHANGELOG.md)
- [Commits](https://github.com/gatsbyjs/gatsby/compare/gatsby@2.1.4...gatsby@2.1.13)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-02-20 19:15:55 -05:00