Skip to content

Commit

Permalink
fix: update .incache data + Github repo authentication dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
sghoweri committed Feb 4, 2020
1 parent 931e284 commit 0231c60
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 24 deletions.
2 changes: 1 addition & 1 deletion docs-site/.incache

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions packages/build-tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@
"@bolt/sassdoc-webpack-plugin": "^2.16.0",
"@bolt/svg-transform-loader": "^2.16.0",
"@bolt/twig-renderer": "^2.16.0",
"@octokit/auth-token": "^2.4.0",
"@octokit/plugin-throttling": "^2.6.0",
"@octokit/rest": "^16.27.3",
"@octokit/plugin-throttling": "^3.2.0",
"@octokit/rest": "^16.43.1",
"@octokit/core": "^2.4.0",
"address": "^1.1.2",
"array-sort": "^1.0.0",
"autoprefixer": "^9.7.4",
Expand Down
18 changes: 5 additions & 13 deletions packages/build-tools/tasks/api-tasks/bolt-versions.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,9 @@ const ora = require('ora');
const chalk = require('chalk');
const checkLinks = require('check-links');
const InCache = require('incache');
const Octokit = require('@octokit/rest').plugin(
require('@octokit/plugin-throttling'),
);
const { createTokenAuth } = require('@octokit/auth-token');
const { Octokit } = require("@octokit/rest");
const { throttling } = require("@octokit/plugin-throttling");
const MyOctokit = Octokit.plugin(throttling);

let versionSpinner;

Expand Down Expand Up @@ -50,15 +49,8 @@ async function getBoltTags() {
} else {
try {
// moved to the try/catch to gracefully handle the GITHUB_TOKEN env not being available
const octokit = new Octokit({
authStrategy: createTokenAuth(process.env.GITHUB_TOKEN),
auth() {
if (process.env.GITHUB_TOKEN) {
return `token ${process.env.GITHUB_TOKEN}`;
} else {
return undefined;
}
},
const octokit = new MyOctokit({
auth: "token " + process.env.GITHUB_TOKEN || undefined,
throttle: {
onRateLimit: (retryAfter, options) => {
console.warn(
Expand Down
34 changes: 27 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2276,6 +2276,18 @@
dependencies:
"@octokit/types" "^2.0.0"

"@octokit/core@^2.4.0":
version "2.4.0"
resolved "https://registry.yarnpkg.com/@octokit/core/-/core-2.4.0.tgz#6a55366dd7cd366827e5804be8021002dbd6cd7b"
integrity sha512-MNwnsDBBxlJWFd1JOhXaCZ9xm8nciWb4lVloGJUSSRxqM0BrvqguWMk4vj1L5dB4juuh1LPuL6/DxSLC4SAfZQ==
dependencies:
"@octokit/auth-token" "^2.4.0"
"@octokit/graphql" "^4.3.1"
"@octokit/request" "^5.3.1"
"@octokit/types" "^2.0.0"
before-after-hook "^2.1.0"
universal-user-agent "^4.0.0"

"@octokit/endpoint@^5.5.0":
version "5.5.1"
resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-5.5.1.tgz#2eea81e110ca754ff2de11c79154ccab4ae16b3f"
Expand All @@ -2285,7 +2297,7 @@
is-plain-object "^3.0.0"
universal-user-agent "^4.0.0"

"@octokit/graphql@^4.0.0":
"@octokit/graphql@^4.0.0", "@octokit/graphql@^4.3.1":
version "4.3.1"
resolved "https://registry.yarnpkg.com/@octokit/graphql/-/graphql-4.3.1.tgz#9ee840e04ed2906c7d6763807632de84cdecf418"
integrity sha512-hCdTjfvrK+ilU2keAdqNBWOk+gm1kai1ZcdjRfB30oA3/T6n53UVJb7w0L5cR3/rhU91xT3HSqCd+qbvH06yxA==
Expand Down Expand Up @@ -2338,6 +2350,14 @@
dependencies:
bottleneck "^2.15.3"

"@octokit/plugin-throttling@^3.2.0":
version "3.2.0"
resolved "https://registry.yarnpkg.com/@octokit/plugin-throttling/-/plugin-throttling-3.2.0.tgz#e900bb4e5976ea45ccb2c32c068d09c28fed31ef"
integrity sha512-4tyTbRFu7OTJFssdj6j74PdvJ8LqMVBFYeRd4+jBJm68LbqmgHunujwvyfjHGp2L+HwC69/BT36PKRWF131Vdg==
dependencies:
"@octokit/types" "^2.0.1"
bottleneck "^2.15.3"

"@octokit/request-error@^1.0.1", "@octokit/request-error@^1.0.2":
version "1.2.0"
resolved "https://registry.yarnpkg.com/@octokit/request-error/-/request-error-1.2.0.tgz#a64d2a9d7a13555570cd79722de4a4d76371baaa"
Expand All @@ -2347,7 +2367,7 @@
deprecation "^2.0.0"
once "^1.4.0"

"@octokit/request@^5.0.0", "@octokit/request@^5.2.0", "@octokit/request@^5.3.0":
"@octokit/request@^5.0.0", "@octokit/request@^5.2.0", "@octokit/request@^5.3.0", "@octokit/request@^5.3.1":
version "5.3.1"
resolved "https://registry.yarnpkg.com/@octokit/request/-/request-5.3.1.tgz#3a1ace45e6f88b1be4749c5da963b3a3b4a2f120"
integrity sha512-5/X0AL1ZgoU32fAepTfEoggFinO3rxsMLtzhlUX+RctLrusn/CApJuGFCd0v7GMFhF+8UiCsTTfsu7Fh1HnEJg==
Expand Down Expand Up @@ -2415,10 +2435,10 @@
once "^1.4.0"
universal-user-agent "^4.0.0"

"@octokit/rest@^16.27.3":
version "16.43.0"
resolved "https://registry.yarnpkg.com/@octokit/rest/-/rest-16.43.0.tgz#519ac030b5c3604afde6550720ff56513aee32aa"
integrity sha512-u+OwrTxHuppVcssGmwCmb4jgPNzsRseJ2rS5PrZk2ASC+WkaF5Q7wu8zVtJ4OA24jK6aRymlwA2uwL36NU9nAA==
"@octokit/rest@^16.43.1":
version "16.43.1"
resolved "https://registry.yarnpkg.com/@octokit/rest/-/rest-16.43.1.tgz#3b11e7d1b1ac2bbeeb23b08a17df0b20947eda6b"
integrity sha512-gfFKwRT/wFxq5qlNjnW2dh+qh74XgTQ2B179UX5K1HYCluioWj8Ndbgqw2PVqa1NnVJkGHp2ovMpVn/DImlmkw==
dependencies:
"@octokit/auth-token" "^2.4.0"
"@octokit/plugin-paginate-rest" "^1.1.1"
Expand Down Expand Up @@ -4304,7 +4324,7 @@ bcryptjs@^2.3.0:
resolved "https://registry.yarnpkg.com/bcryptjs/-/bcryptjs-2.4.3.tgz#9ab5627b93e60621ff7cdac5da9733027df1d0cb"
integrity sha1-mrVie5PmBiH/fNrF2pczAn3x0Ms=

before-after-hook@^2.0.0:
before-after-hook@^2.0.0, before-after-hook@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/before-after-hook/-/before-after-hook-2.1.0.tgz#b6c03487f44e24200dd30ca5e6a1979c5d2fb635"
integrity sha512-IWIbu7pMqyw3EAJHzzHbWa85b6oud/yfKYg5rqB5hNE8CeMi3nX+2C2sj0HswfblST86hpVEOAb9x34NZd6P7A==
Expand Down

0 comments on commit 0231c60

Please sign in to comment.