chris48s
c73072deed
Remove requestOptions2GotOptions compatibility layer ( #7270 )
...
* gzip --> decompress
* strictSSL --> https.rejectUnauthorized
* auth --> username/password
* qs --> searchParams
* fix base service auth docs
* completely remove requestOptions2GotOptions layer
* update the docs
Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
2021-11-15 19:56:08 +00:00
Caleb Cartwright
e4e7b09009
Add a render helper for downloads badges, run [amo ansible apm chromewebstore clojars conda crates docker dub eclipse gem githubdownloads] ( #7163 )
...
* refactor: add render helper for downloads badges
* refactor: use new helper in some download badge classes
* doc renderer function
Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
2021-10-26 23:19:20 +00:00
Pierre-Yves B
23c0406bed
Migrate from CommonJS to ESM ( #6651 )
2021-07-09 12:53:55 +01:00
dependabot-preview[bot]
ee83590942
Build(deps-dev): bump @typescript-eslint/eslint-plugin from 2.34.0 to 4.19.0, run [GitHub GitlabCoverage F-Droid Wordpress VisualStudioAppCenter Ore Packagist] ( #6319 )
...
* Build(deps-dev): bump @typescript-eslint/eslint-plugin
Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin ) from 2.34.0 to 4.19.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases )
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/CHANGELOG.md )
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.19.0/packages/eslint-plugin )
Signed-off-by: dependabot-preview[bot] <support@dependabot.com >
* chore: update eslint camelcase rule
* chore: eslint camelcase updates for wordpress
* chore: fix eslint camelcase for misc other services
* chore: fix eslint camelcase issue in github and gitlab
* chore: run prettier
* chore: account for JSX globals
* deps: bump typescript-eslint-parser to v4
* chore: frontend lint changes
* chore: update eslint config to only run @typescript-eslint/explicit-module-boundary-types on ts files
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Caleb Cartwright <caleb.cartwright@outlook.com >
2021-03-28 08:26:01 -05:00
Hubert Jagodziński
c6d97de22e
[GithubCommitsSince GithubDownloads GithubRelease] GithubDownloads supports latest release by SemVer ( #5756 )
...
* Latest release by SemVer
* Tests covering altered behavior
Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
2020-10-31 04:59:31 +00:00
chris48s
504015c0ba
migrate hapi/joi to joi ( #5624 )
...
* update joi + joi-extension-semver
* @hapi/joi --> joi
Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
2020-09-30 17:51:02 +00:00
Caleb Cartwright
5a3064d0d4
convert some service classes to static fields, run [GitHubCommitsSince GitHubContributors GitHubDeployments GitHubDownloads GitHubFollowers] ( #5585 )
...
* refactor(githubcommitssince): convert to static fields
* refactor(githubcontributors): convert to static fields
* refactor(githubdeployments): convert to static fields
* refactor(githubdownloads): convert to static fields
* refactor(githubfollowers): convert to static fields
2020-09-21 11:25:15 -04:00
dependabot-preview[bot]
478d14300c
Build(deps-dev): bump eslint-plugin-import from 2.20.1 to 2.20.2 ( #4859 )
...
* Build(deps-dev): bump eslint-plugin-import from 2.20.1 to 2.20.2
Bumps [eslint-plugin-import](https://github.com/benmosher/eslint-plugin-import ) from 2.20.1 to 2.20.2.
- [Release notes](https://github.com/benmosher/eslint-plugin-import/releases )
- [Changelog](https://github.com/benmosher/eslint-plugin-import/blob/master/CHANGELOG.md )
- [Commits](https://github.com/benmosher/eslint-plugin-import/compare/v2.20.1...v2.20.2 )
Signed-off-by: dependabot-preview[bot] <support@dependabot.com >
* Fixes
* refactor: combine imports
* refactor: combine imports
* refactor: combine imports
* refactor: update import ordering
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
Co-authored-by: Paul Melnikow <email@paulmelnikow.com >
Co-authored-by: Caleb Cartwright <calebcartwright@users.noreply.github.com >
Co-authored-by: Caleb Cartwright <caleb.cartwright@outlook.com >
2020-04-16 18:39:13 -05:00
Pierre-Yves B
157a6180b2
Make search work with category names ( #4103 )
2019-10-02 20:03:59 +01:00
Caleb Cartwright
76b2e2634a
fix(GitHubDownloads): type error on latest with pre-downloads ( #4030 )
2019-09-16 01:08:39 +00:00
chris48s
75ee413178
Add BaseGraphqlService, support [github] V4 API ( #3763 )
...
* add base class for Graphql APIs
* add GithubAuthV4Service + updates to GH token pool
* update github forks to use GithubAuthV4Service
* rename GithubAuthService to GithubAuthV3Service
2019-07-29 21:42:03 +01:00
dependabot-preview[bot]
294aa1e1df
Build(deps-dev): bump eslint-plugin-import from 2.17.3 to 2.18.0; autofixes ( #3671 )
...
* Build(deps-dev): bump eslint-plugin-import from 2.17.3 to 2.18.0
Bumps [eslint-plugin-import](https://github.com/benmosher/eslint-plugin-import ) from 2.17.3 to 2.18.0.
- [Release notes](https://github.com/benmosher/eslint-plugin-import/releases )
- [Changelog](https://github.com/benmosher/eslint-plugin-import/blob/master/CHANGELOG.md )
- [Commits](https://github.com/benmosher/eslint-plugin-import/compare/v2.17.3...v2.18.0 )
Signed-off-by: dependabot-preview[bot] <support@dependabot.com >
* Autofixes
2019-07-08 12:13:46 -04:00
chris48s
8621fe42d7
Upgrade Joi ( #3505 )
...
* upgrade joi
* find & replace ALL THE THINGS
* update related deps
2019-06-02 21:59:55 +01:00
chris48s
5f29f6a175
case-insentitive asset name compare in [githubdownloads] ( #3377 )
...
closes #3364
2019-04-29 15:05:27 +01:00
Paul Melnikow
ca22d01606
Rewrite [GithubDownloads] ( #3351 )
...
For consistency with other download badges, I changed some formatting:
- **downloads | 24k total** -> **downloads | 24k**
- **downloads | 3k** -> **downloads@latest | 3k**
- **downloads | 3k v0.29.0** -> **downloads@v0.29 .0 | 3k**
Ref #2863
2019-04-22 22:55:31 -04:00
Denis Duliçi
48e454c63d
Fixed GitHub release downloads, run [GithubDownloads] ( #3256 )
...
* fixed github release downloads
* npm run prettier code push.
* master package-lock.json file
2019-04-03 17:28:48 -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
47e8cc3de3
Refactor route functions in BaseService ( #2860 )
...
The route helper functions are fairly well isolated from the rest of BaseService, with a few convenient entry points. They are easier to test in isolation.
The way the code was written before, `pathToRegexp` was invoked once for every request, which seems inefficient.
`route` was validated when it was used, though it seems more helpful to validate it up front.
This breaks out `_makeFullUrl`, `_regex`, `_regexFromPath` into new helper functions `makeFullUrl`, `assertValidRoute`, `prepareRoute`, and `namedParamsForMatch`.
It adds validation to route, and updates the services without patterns to include one, in order to pass the new validation rules.
2019-01-26 02:38:12 -05:00
chris48s
fba846986a
fix logo imports in [github twitter liberapay] ( #2817 )
...
this was moved in #2796 but we missed updating some of the imports
2019-01-20 23:19:12 -05:00
chris48s
796d066930
remove asterisks from examples ( #2749 )
2019-01-13 12:17:39 +00:00
Paul Melnikow
b36a9040f3
Add warning banners to legacy services ( #2546 )
2018-12-18 20:52:17 +00:00
Paul Melnikow
88c8b0ee3e
More example urls and static examples [apm waffle] ( #2478 )
2018-12-11 16:31:01 -05:00
Paul Melnikow
fe05d00747
Move github examples into services/github ( #2309 )
2018-11-15 15:57:56 -05:00
Paul Melnikow
83ac6ff1b3
Enforce use of template literals ( #2242 )
...
This is consistent with what we're pretty much already doing, and saves us from making the request during code review.
These were all autofixed and most of them seem easier to read. Some in the legacy services should be rewritten in more legible forms during refactor (ie using intermediate variables, or using request’s qs option). There are some in helper functions and elsewhere that should get rewritten separately. I don't want to change them in this PR because the changes will get lost in this diff, though we could identify them here and fix them before or just after.
2018-11-02 17:11:44 -04:00
Paul Melnikow
bedba47d77
Move legacy services from server.js into services/ ( #1958 )
...
This builds on the work of #1931 by moving the legacy services into `services/`.
2018-08-27 13:29:54 -04:00