Compare commits

..

6 Commits

Author SHA1 Message Date
semantic-release-bot c72844caa4 build(release): 1.2.0 [skip ci]
# [1.2.0](https://github.com/actions/create-github-app-token/compare/v1.1.5...v1.2.0) (2023-08-29)

### Features

* add GitHub Enterprise Server (GHES) support ([#36](https://github.com/actions/create-github-app-token/issues/36)) ([ede6c15](https://github.com/actions/create-github-app-token/commit/ede6c158812854da7c63aa6635138d168de14bea))
2023-08-29 23:14:09 +00:00
7Hazard ede6c15881 feat: add GitHub Enterprise Server (GHES) support (#36)
This adds support for this action to be used in GitHub Enterprise
Server.

It sends request to the base url extracted from
[GITHUB_API_URL](https://docs.github.com/en/enterprise-server@3.10/actions/learn-github-actions/variables#default-environment-variables).

---------

Co-authored-by: Gregor Martynus <39992+gr2m@users.noreply.github.com>
2023-08-29 16:13:34 -07:00
semantic-release-bot 17cde8a7d8 build(release): 1.1.5 [skip ci]
## [1.1.5](https://github.com/actions/create-github-app-token/compare/v1.1.4...v1.1.5) (2023-08-28)

### Bug Fixes

* **release:** update version in `package.json` ([#35](https://github.com/actions/create-github-app-token/issues/35)) ([1dccc4c](https://github.com/actions/create-github-app-token/commit/1dccc4ccc6e1df7d6adc1bde339ce0d7a2ea7df7)), closes [#34](https://github.com/actions/create-github-app-token/issues/34)
2023-08-28 22:38:26 +00:00
Gregor Martynus 1dccc4ccc6 fix(release): update version in package.json (#35)
closes #34

Co-authored-by: Parker Brown <17183625+parkerbxyz@users.noreply.github.com>
2023-08-28 15:37:47 -07:00
semantic-release-bot 35d8ea9fdb build(release): 1.1.4 [skip ci]
## [1.1.4](https://github.com/actions/create-github-app-token/compare/v1.1.3...v1.1.4) (2023-08-28)

### Bug Fixes

* **release:** build `dist/` before release ([#33](https://github.com/actions/create-github-app-token/issues/33)) ([9a6a017](https://github.com/actions/create-github-app-token/commit/9a6a017c104eb1b36533ee8195e814f567934ce8)), closes [#32](https://github.com/actions/create-github-app-token/issues/32)
2023-08-28 22:29:27 +00:00
Gregor Martynus 9a6a017c10 fix(release): build dist/ before release (#33)
closes #32
2023-08-28 15:28:55 -07:00
7 changed files with 1062 additions and 6779 deletions
+2 -1
View File
@@ -23,6 +23,7 @@ jobs:
with:
token: ${{ steps.app-token.outputs.token }}
- run: npm install --no-save @semantic-release/git semantic-release-plugin-github-breaking-version-tag
- run: npx semantic-release
- run: npm run build
- run: npx semantic-release --debug
env:
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
+786 -3555
View File
File diff suppressed because one or more lines are too long
+249 -3209
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -11,7 +11,7 @@ export async function post(core, request) {
const token = core.getState("token");
if (!token) return;
await request("DELETE /installation/token", {
headers: {
authorization: `token ${token}`,
+13 -6
View File
@@ -15,9 +15,16 @@ const privateKey = core.getInput("private_key");
const repository = process.env.GITHUB_REPOSITORY;
main(appId, privateKey, repository, core, createAppAuth, request).catch(
(error) => {
console.error(error);
core.setFailed(error.message);
}
);
main(
appId,
privateKey,
repository,
core,
createAppAuth,
request.defaults({
baseUrl: process.env["GITHUB_API_URL"],
})
).catch((error) => {
console.error(error);
core.setFailed(error.message);
});
+2 -1
View File
@@ -2,7 +2,7 @@
"name": "create-github-app-token",
"private": true,
"type": "module",
"version": "1.0.5",
"version": "1.2.0",
"description": "GitHub Action for creating a GitHub App Installation Access Token",
"scripts": {
"build": "esbuild main.js post.js --bundle --outdir=dist --out-extension:.js=.cjs --platform=node --target=node16.16",
@@ -27,6 +27,7 @@
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/github",
"@semantic-release/npm",
"semantic-release-plugin-github-breaking-version-tag",
[
"@semantic-release/git",
+9 -6
View File
@@ -5,9 +5,12 @@ import { request } from "@octokit/request";
import { post } from "./lib/post.js";
post(core, request).catch(
(error) => {
console.error(error);
core.setFailed(error.message);
}
);
post(
core,
request.defaults({
baseUrl: process.env["GITHUB_API_URL"],
})
).catch((error) => {
console.error(error);
core.setFailed(error.message);
});