fix DateTime import

This commit is contained in:
jpaul 2023-11-27 14:51:56 +01:00
parent e9bf44a5db
commit 9186a025e4
5 changed files with 14818 additions and 21 deletions

7404
dist/cleanup/index.js generated vendored

File diff suppressed because it is too large Load Diff

7404
dist/main/index.js generated vendored

File diff suppressed because it is too large Load Diff

27
package-lock.json generated
View File

@ -21,12 +21,14 @@
"@octokit/rest": "^20.0.2", "@octokit/rest": "^20.0.2",
"@octokit/types": "^6.34.0", "@octokit/types": "^6.34.0",
"js-base64": "^3.7.5", "js-base64": "^3.7.5",
"luxon": "^3.4.4",
"octokit": "^3.1.1", "octokit": "^3.1.1",
"semver": "^7.5.2", "semver": "^7.5.2",
"uuid": "^8.3.2" "uuid": "^8.3.2"
}, },
"devDependencies": { "devDependencies": {
"@types/jest": "^27.5.2", "@types/jest": "^27.5.2",
"@types/luxon": "^3.3.5",
"@types/node": "^18.15.11", "@types/node": "^18.15.11",
"@types/semver": "^7.3.13", "@types/semver": "^7.3.13",
"@types/uuid": "^8.3.4", "@types/uuid": "^8.3.4",
@ -2754,6 +2756,12 @@
"@types/node": "*" "@types/node": "*"
} }
}, },
"node_modules/@types/luxon": {
"version": "3.3.5",
"resolved": "https://registry.npmjs.org/@types/luxon/-/luxon-3.3.5.tgz",
"integrity": "sha512-1cyf6Ge/94zlaWIZA2ei1pE6SZ8xpad2hXaYa5JEFiaUH0YS494CZwyi4MXNpXD9oEuv6ZH0Bmh0e7F9sPhmZA==",
"dev": true
},
"node_modules/@types/node": { "node_modules/@types/node": {
"version": "18.15.11", "version": "18.15.11",
"resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.11.tgz", "resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.11.tgz",
@ -6762,6 +6770,14 @@
"yallist": "^3.0.2" "yallist": "^3.0.2"
} }
}, },
"node_modules/luxon": {
"version": "3.4.4",
"resolved": "https://registry.npmjs.org/luxon/-/luxon-3.4.4.tgz",
"integrity": "sha512-zobTr7akeGHnv7eBOXcRgMeCP6+uyYsczwmeRCauvpvaAltgNyTbLH/+VaEAPUeWBT+1GuNmz4wC/6jtQzbbVA==",
"engines": {
"node": ">=12"
}
},
"node_modules/make-dir": { "node_modules/make-dir": {
"version": "3.1.0", "version": "3.1.0",
"resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz", "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz",
@ -10830,6 +10846,12 @@
"@types/node": "*" "@types/node": "*"
} }
}, },
"@types/luxon": {
"version": "3.3.5",
"resolved": "https://registry.npmjs.org/@types/luxon/-/luxon-3.3.5.tgz",
"integrity": "sha512-1cyf6Ge/94zlaWIZA2ei1pE6SZ8xpad2hXaYa5JEFiaUH0YS494CZwyi4MXNpXD9oEuv6ZH0Bmh0e7F9sPhmZA==",
"dev": true
},
"@types/node": { "@types/node": {
"version": "18.15.11", "version": "18.15.11",
"resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.11.tgz", "resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.11.tgz",
@ -13804,6 +13826,11 @@
"yallist": "^3.0.2" "yallist": "^3.0.2"
} }
}, },
"luxon": {
"version": "3.4.4",
"resolved": "https://registry.npmjs.org/luxon/-/luxon-3.4.4.tgz",
"integrity": "sha512-zobTr7akeGHnv7eBOXcRgMeCP6+uyYsczwmeRCauvpvaAltgNyTbLH/+VaEAPUeWBT+1GuNmz4wC/6jtQzbbVA=="
},
"make-dir": { "make-dir": {
"version": "3.1.0", "version": "3.1.0",
"resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz", "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-3.1.0.tgz",

View File

@ -39,12 +39,14 @@
"@octokit/rest": "^20.0.2", "@octokit/rest": "^20.0.2",
"@octokit/types": "^6.34.0", "@octokit/types": "^6.34.0",
"js-base64": "^3.7.5", "js-base64": "^3.7.5",
"luxon": "^3.4.4",
"octokit": "^3.1.1", "octokit": "^3.1.1",
"semver": "^7.5.2", "semver": "^7.5.2",
"uuid": "^8.3.2" "uuid": "^8.3.2"
}, },
"devDependencies": { "devDependencies": {
"@types/jest": "^27.5.2", "@types/jest": "^27.5.2",
"@types/luxon": "^3.3.5",
"@types/node": "^18.15.11", "@types/node": "^18.15.11",
"@types/semver": "^7.3.13", "@types/semver": "^7.3.13",
"@types/uuid": "^8.3.4", "@types/uuid": "^8.3.4",

View File

@ -11,10 +11,10 @@ import {Base64} from "js-base64";
import {Octokit} from '@octokit/rest'; import {Octokit} from '@octokit/rest';
import fetch from "node-fetch"; import fetch from "node-fetch";
import {Context} from "@actions/github/lib/context"; import {Context} from "@actions/github/lib/context";
import { DateTime } from 'luxon'
// Set up Octokit for github.com only and in the same way as @actions/github (see https://git.io/Jy9YP) // Set up Octokit for github.com only and in the same way as @actions/github (see https://git.io/Jy9YP)
const baseUrl = 'https://api.github.com' const baseUrl = 'https://api.github.com'
const { DateTime } = require('luxon');
const GitHubDotCom = Octokit.defaults({ const GitHubDotCom = Octokit.defaults({
baseUrl, baseUrl,
request: { request: {