fix octokit import

This commit is contained in:
jpaul 2023-11-07 16:36:03 +01:00
parent 53822087e9
commit 26baf45152
5 changed files with 9767 additions and 83 deletions

3780
dist/cleanup/index.js generated vendored

File diff suppressed because it is too large Load Diff

3780
dist/main/index.js generated vendored

File diff suppressed because it is too large Load Diff

2262
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -36,8 +36,10 @@
"@actions/io": "^1.1.1",
"@actions/tool-cache": "^1.7.1",
"@octokit/core": "^3.5.1",
"@octokit/rest": "^20.0.2",
"@octokit/types": "^6.34.0",
"js-base64": "^3.7.5",
"octokit": "^3.1.1",
"semver": "^7.5.2",
"uuid": "^8.3.2"
},

View File

@ -7,7 +7,7 @@ import {tmpdir} from 'os'
import {createPRComment, isPREvent, toSemVer} from '../utils'
import {gte} from 'semver'
import {Base64} from 'js-base64';
import objectContaining = jasmine.objectContaining;
import { Octokit } from '@octokit/rest';
const BUILD_OUTPUT_JSON_PATH = join(tmpdir(), 'native-image-build-output.json')
const BYTES_TO_KiB = 1024
@ -22,11 +22,8 @@ const NATIVE_IMAGE_CONFIG_FILE = join(
'native-image-options.properties'
)
const NATIVE_IMAGE_CONFIG_FILE_ENV = 'NATIVE_IMAGE_CONFIG_FILE'
const { Octokit } = require("@octokit/rest");
const {
createOrUpdateTextFile,
composeCreateOrUpdateTextFile,
} = require("@octokit/plugin-create-or-update-text-file");
//const { Octokit } = require("@octokit/rest");
let REPORT_TOKEN = '';
interface AnalysisResult {
@ -142,7 +139,6 @@ export async function generateReports(): Promise<void> {
const contentEncoded = Base64.encode(JSON.stringify(buildOutput))
const { data } = await octokit.repos.createOrUpdateFileContents({
owner: 'jessiscript',
repo: 're23_build_tracking',