mirror of
https://github.com/peter-evans/create-pull-request.git
synced 2026-09-30 17:40:55 +08:00
Compare commits
20
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
abadea5d94 | ||
|
|
11e8dc7c9c | ||
|
|
c9f8b51aaa | ||
|
|
1a3c7ab17d | ||
|
|
762a4a5ab1 | ||
|
|
b99c9ae23b | ||
|
|
11fa467881 | ||
|
|
92f6f0bc90 | ||
|
|
7ec5aae3c9 | ||
|
|
c66b8cb005 | ||
|
|
653ba8b281 | ||
|
|
6fff569d74 | ||
|
|
a78ae501dd | ||
|
|
de36595094 | ||
|
|
5f42108561 | ||
|
|
8c5aeef7f4 | ||
|
|
8b4b9968cb | ||
|
|
aa523f9db6 | ||
|
|
d8c15c739f | ||
|
|
eec7ab75b2 |
@@ -5,6 +5,8 @@ updates:
|
||||
schedule:
|
||||
interval: "monthly"
|
||||
day: "tuesday"
|
||||
cooldown:
|
||||
default-days: 3
|
||||
labels:
|
||||
- "dependencies"
|
||||
groups:
|
||||
@@ -17,6 +19,8 @@ updates:
|
||||
schedule:
|
||||
interval: "monthly"
|
||||
day: "tuesday"
|
||||
cooldown:
|
||||
default-days: 3
|
||||
ignore:
|
||||
- dependency-name: "*"
|
||||
update-types: ["version-update:semver-major"]
|
||||
|
||||
@@ -6,7 +6,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.actor == 'dependabot[bot]'
|
||||
steps:
|
||||
- uses: peter-evans/enable-pull-request-automerge@v3
|
||||
- uses: peter-evans/enable-pull-request-automerge@a660677d5469627102a1c1e11409dd063606628d # v3.0.0
|
||||
with:
|
||||
token: ${{ secrets.ACTIONS_BOT_TOKEN }}
|
||||
pull-request-number: ${{ github.event.pull_request.number }}
|
||||
|
||||
+13
-13
@@ -19,8 +19,8 @@ jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: actions/setup-node@v6
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
- uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
|
||||
with:
|
||||
node-version-file: package.json
|
||||
cache: npm
|
||||
@@ -29,11 +29,11 @@ jobs:
|
||||
- run: npm run format-check
|
||||
- run: npm run lint
|
||||
- run: npm run test
|
||||
- uses: actions/upload-artifact@v7
|
||||
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
||||
with:
|
||||
name: dist
|
||||
path: dist
|
||||
- uses: actions/upload-artifact@v7
|
||||
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
||||
with:
|
||||
name: action.yml
|
||||
path: action.yml
|
||||
@@ -46,16 +46,16 @@ jobs:
|
||||
matrix:
|
||||
target: [built, committed]
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
with:
|
||||
ref: main
|
||||
- if: matrix.target == 'built' || github.event_name == 'pull_request'
|
||||
uses: actions/download-artifact@v8
|
||||
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
|
||||
with:
|
||||
name: dist
|
||||
path: dist
|
||||
- if: matrix.target == 'built' || github.event_name == 'pull_request'
|
||||
uses: actions/download-artifact@v8
|
||||
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
|
||||
with:
|
||||
name: action.yml
|
||||
path: .
|
||||
@@ -80,7 +80,7 @@ jobs:
|
||||
branch: ci-test-${{ matrix.target }}-${{ github.sha }}
|
||||
|
||||
- name: Close Pull
|
||||
uses: peter-evans/close-pull@v3
|
||||
uses: peter-evans/close-pull@a192af8d70f2d49c49643134605c3b73d4f80fae # v3.0.1
|
||||
with:
|
||||
pull-request-number: ${{ steps.cpr.outputs.pull-request-number }}
|
||||
comment: '[CI] test ${{ matrix.target }}'
|
||||
@@ -92,7 +92,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Find Comment
|
||||
uses: peter-evans/find-comment@v4
|
||||
uses: peter-evans/find-comment@b30e6a3c0ed37e7c023ccd3f1db5c6c0b0c23aad # v4.0.0
|
||||
id: fc
|
||||
with:
|
||||
issue-number: ${{ github.event.number }}
|
||||
@@ -101,7 +101,7 @@ jobs:
|
||||
|
||||
- if: steps.fc.outputs.comment-id == ''
|
||||
name: Create comment
|
||||
uses: peter-evans/create-or-update-comment@v5
|
||||
uses: peter-evans/create-or-update-comment@e8674b075228eee787fea43ef493e45ece1004c9 # v5.0.0
|
||||
with:
|
||||
issue-number: ${{ github.event.number }}
|
||||
body: |
|
||||
@@ -118,13 +118,13 @@ jobs:
|
||||
needs: [test]
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: actions/download-artifact@v8
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
|
||||
with:
|
||||
name: dist
|
||||
path: dist
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v8
|
||||
uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1
|
||||
with:
|
||||
token: ${{ secrets.ACTIONS_BOT_TOKEN }}
|
||||
commit-message: 'build: update distribution'
|
||||
|
||||
@@ -6,7 +6,7 @@ jobs:
|
||||
createPullRequest:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
|
||||
- name: Make changes to pull request
|
||||
run: date +%s > report.txt
|
||||
@@ -42,7 +42,7 @@ jobs:
|
||||
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"
|
||||
|
||||
- name: Add reaction
|
||||
uses: peter-evans/create-or-update-comment@v5
|
||||
uses: peter-evans/create-or-update-comment@e8674b075228eee787fea43ef493e45ece1004c9 # v5.0.0
|
||||
with:
|
||||
repository: ${{ github.event.client_payload.github.payload.repository.full_name }}
|
||||
comment-id: ${{ github.event.client_payload.github.payload.comment.id }}
|
||||
|
||||
@@ -7,7 +7,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Slash Command Dispatch
|
||||
uses: peter-evans/slash-command-dispatch@v5
|
||||
uses: peter-evans/slash-command-dispatch@9bdcd7914ec1b75590b790b844aa3b8eee7c683a # v5.0.2
|
||||
with:
|
||||
token: ${{ secrets.ACTIONS_BOT_TOKEN }}
|
||||
config: >
|
||||
|
||||
@@ -18,7 +18,7 @@ jobs:
|
||||
tag:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
with:
|
||||
token: ${{ secrets.ACTIONS_BOT_TOKEN }}
|
||||
fetch-depth: 0
|
||||
@@ -27,6 +27,11 @@ jobs:
|
||||
git config user.name actions-bot
|
||||
git config user.email actions-bot@users.noreply.github.com
|
||||
- name: Tag new target
|
||||
run: git tag -f ${{ github.event.inputs.main_version }} ${{ github.event.inputs.target }}
|
||||
run: git tag -f "${INPUT_MAIN_VERSION}" "${INPUT_TARGET}"
|
||||
env:
|
||||
INPUT_MAIN_VERSION: ${{ github.event.inputs.main_version }}
|
||||
INPUT_TARGET: ${{ github.event.inputs.target }}
|
||||
- name: Push new tag
|
||||
run: git push origin ${{ github.event.inputs.main_version }} --force
|
||||
run: git push origin "${INPUT_MAIN_VERSION}" --force
|
||||
env:
|
||||
INPUT_MAIN_VERSION: ${{ github.event.inputs.main_version }}
|
||||
|
||||
@@ -4,10 +4,10 @@ import {
|
||||
getWorkingBaseAndType,
|
||||
buildBranchCommits
|
||||
} from '../lib/create-or-update-branch'
|
||||
import {randomUUID} from 'crypto'
|
||||
import * as fs from 'fs'
|
||||
import {GitCommandManager} from '../lib/git-command-manager'
|
||||
import * as path from 'path'
|
||||
import {v4 as uuidv4} from 'uuid'
|
||||
|
||||
const REPO_PATH = '/git/local/repos/test-base'
|
||||
const REMOTE_NAME = 'origin'
|
||||
@@ -31,7 +31,7 @@ const ADD_PATHS_MULTI = ['a', 'b']
|
||||
const ADD_PATHS_WILDCARD = ['a/*.txt', 'b/*.txt']
|
||||
|
||||
async function createFile(filename: string, content?: string): Promise<string> {
|
||||
const _content = content ? content : uuidv4()
|
||||
const _content = content ? content : randomUUID()
|
||||
const filepath = path.join(REPO_PATH, filename)
|
||||
await fs.promises.mkdir(path.dirname(filepath), {recursive: true})
|
||||
await fs.promises.writeFile(filepath, _content, {encoding: 'utf8'})
|
||||
@@ -82,7 +82,7 @@ async function createCommits(
|
||||
} else {
|
||||
result.changes = await createChanges()
|
||||
}
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
await git.exec(['add', '-A'])
|
||||
await git.commit(['-m', commitMessage])
|
||||
result.commitMsgs.unshift(commitMessage)
|
||||
@@ -313,7 +313,7 @@ describe('create-or-update-branch tests', () => {
|
||||
})
|
||||
|
||||
it('tests no changes resulting in no new branch being created', async () => {
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -330,7 +330,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update with a tracked file change', async () => {
|
||||
// Create a tracked file change
|
||||
const trackedContent = await createFile(TRACKED_FILE)
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -359,7 +359,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create a tracked file change
|
||||
const _trackedContent = await createFile(TRACKED_FILE)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -381,7 +381,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update with an untracked file change', async () => {
|
||||
// Create an untracked file change
|
||||
const untrackedContent = await createFile(UNTRACKED_FILE)
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -410,7 +410,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create an untracked file change
|
||||
const _untrackedContent = await createFile(UNTRACKED_FILE)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -434,7 +434,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -464,7 +464,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create identical tracked and untracked file changes
|
||||
await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -486,7 +486,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update with commits on the base inbetween', async () => {
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -524,7 +524,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -556,7 +556,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -585,7 +585,7 @@ describe('create-or-update-branch tests', () => {
|
||||
await beforeTest()
|
||||
|
||||
// Running with no update effectively reverts the branch back to match the base
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -607,7 +607,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -648,7 +648,7 @@ describe('create-or-update-branch tests', () => {
|
||||
commits.changes.tracked,
|
||||
commits.changes.untracked
|
||||
)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -673,7 +673,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -703,7 +703,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create a commit on the base with a partial merge of the changes
|
||||
await createFile(TRACKED_FILE, changes.tracked)
|
||||
const baseCommitMessage = uuidv4()
|
||||
const baseCommitMessage = randomUUID()
|
||||
await git.exec(['add', '-A'])
|
||||
await git.commit(['-m', baseCommitMessage])
|
||||
await git.push([
|
||||
@@ -714,7 +714,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create the same tracked and untracked file changes
|
||||
const _changes = await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -746,7 +746,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -790,7 +790,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create the same tracked and untracked file changes (no change on update)
|
||||
const _changes = await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -816,7 +816,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -845,7 +845,7 @@ describe('create-or-update-branch tests', () => {
|
||||
await beforeTest()
|
||||
|
||||
// Force push the base branch to a different commit
|
||||
const amendedCommitMessage = uuidv4()
|
||||
const amendedCommitMessage = randomUUID()
|
||||
await git.commit(['--amend', '-m', amendedCommitMessage])
|
||||
await git.push([
|
||||
'--force',
|
||||
@@ -855,7 +855,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create the same tracked and untracked file changes (no change on update)
|
||||
const _changes = await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -878,7 +878,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update with commits on the working base (during the workflow)', async () => {
|
||||
// Create commits on the working base
|
||||
const commits = await createCommits(git)
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -910,7 +910,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create commits on the working base
|
||||
const _commits = await createCommits(git)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -937,7 +937,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -973,7 +973,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const _commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1002,7 +1002,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1046,7 +1046,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const _commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1074,7 +1074,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update using a different remote from the base', async () => {
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1104,7 +1104,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1127,7 +1127,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update with signoff on commit', async () => {
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1164,7 +1164,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1194,7 +1194,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update with multiple add-paths', async () => {
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1224,7 +1224,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1247,7 +1247,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create and update with wildcard add-paths', async () => {
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1277,7 +1277,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1300,7 +1300,7 @@ describe('create-or-update-branch tests', () => {
|
||||
it('tests create with add-paths resolving to no changes when other changes exist', async () => {
|
||||
// Create tracked and untracked file changes
|
||||
await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1321,7 +1321,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const resultA = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1365,7 +1365,7 @@ describe('create-or-update-branch tests', () => {
|
||||
// Set the working base to a branch that is not the pull request base
|
||||
await git.checkout(NOT_BASE_BRANCH)
|
||||
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1386,7 +1386,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create a tracked file change
|
||||
const trackedContent = await createFile(TRACKED_FILE)
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1418,7 +1418,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create a tracked file change
|
||||
const _trackedContent = await createFile(TRACKED_FILE)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1443,7 +1443,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create an untracked file change
|
||||
const untrackedContent = await createFile(UNTRACKED_FILE)
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1475,7 +1475,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create an untracked file change
|
||||
const _untrackedContent = await createFile(UNTRACKED_FILE)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1502,7 +1502,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1535,7 +1535,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create identical tracked and untracked file changes
|
||||
await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1560,7 +1560,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1601,7 +1601,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1635,7 +1635,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1667,7 +1667,7 @@ describe('create-or-update-branch tests', () => {
|
||||
await git.checkout(NOT_BASE_BRANCH)
|
||||
|
||||
// Running with no update effectively reverts the branch back to match the base
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1694,7 +1694,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1738,7 +1738,7 @@ describe('create-or-update-branch tests', () => {
|
||||
commits.changes.tracked,
|
||||
commits.changes.untracked
|
||||
)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1768,7 +1768,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1798,7 +1798,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create a commit on the base with a partial merge of the changes
|
||||
await createFile(TRACKED_FILE, changes.tracked)
|
||||
const baseCommitMessage = uuidv4()
|
||||
const baseCommitMessage = randomUUID()
|
||||
await git.exec(['add', '-A'])
|
||||
await git.commit(['-m', baseCommitMessage])
|
||||
await git.push([
|
||||
@@ -1812,7 +1812,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create the same tracked and untracked file changes
|
||||
const _changes = await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1846,7 +1846,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1893,7 +1893,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create the same tracked and untracked file changes (no change on update)
|
||||
const _changes = await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1924,7 +1924,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -1953,7 +1953,7 @@ describe('create-or-update-branch tests', () => {
|
||||
await beforeTest()
|
||||
|
||||
// Force push the base branch to a different commit
|
||||
const amendedCommitMessage = uuidv4()
|
||||
const amendedCommitMessage = randomUUID()
|
||||
await git.commit(['--amend', '-m', amendedCommitMessage])
|
||||
await git.push([
|
||||
'--force',
|
||||
@@ -1966,7 +1966,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create the same tracked and untracked file changes (no change on update)
|
||||
const _changes = await createChanges(changes.tracked, changes.untracked)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -1992,7 +1992,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create commits on the working base
|
||||
const commits = await createCommits(git)
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -2027,7 +2027,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create commits on the working base
|
||||
const _commits = await createCommits(git)
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -2057,7 +2057,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -2096,7 +2096,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const _commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -2128,7 +2128,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -2175,7 +2175,7 @@ describe('create-or-update-branch tests', () => {
|
||||
const _commits = await createCommits(git)
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -2205,7 +2205,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -2238,7 +2238,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -2268,7 +2268,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -2302,7 +2302,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -2329,7 +2329,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -2371,7 +2371,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const _changes = await createChanges()
|
||||
const _commitMessage = uuidv4()
|
||||
const _commitMessage = randomUUID()
|
||||
const _result = await createOrUpdateBranch(
|
||||
git,
|
||||
_commitMessage,
|
||||
@@ -2403,7 +2403,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create commits on the working base
|
||||
const commits = await createCommits(git)
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const result = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
@@ -2428,7 +2428,7 @@ describe('create-or-update-branch tests', () => {
|
||||
|
||||
// Create tracked and untracked file changes
|
||||
const changes = await createChanges()
|
||||
const commitMessage = uuidv4()
|
||||
const commitMessage = randomUUID()
|
||||
const resultA = await createOrUpdateBranch(
|
||||
git,
|
||||
commitMessage,
|
||||
|
||||
@@ -10,7 +10,7 @@ if [[ "$(docker images -q $IMAGE 2> /dev/null)" == "" || $ARG1 == "build" ]]; th
|
||||
cat > Dockerfile << EOF
|
||||
FROM node:20-alpine
|
||||
RUN apk --no-cache add git git-daemon
|
||||
RUN npm install jest jest-environment-jsdom --global
|
||||
RUN npm install jest@30 jest-environment-jsdom@30 --global
|
||||
WORKDIR /cpr
|
||||
COPY __test__/entrypoint.sh /entrypoint.sh
|
||||
ENTRYPOINT ["/entrypoint.sh"]
|
||||
|
||||
Vendored
+8
-688
@@ -55,7 +55,7 @@ exports.tryFetch = tryFetch;
|
||||
exports.buildBranchCommits = buildBranchCommits;
|
||||
exports.createOrUpdateBranch = createOrUpdateBranch;
|
||||
const core = __importStar(__nccwpck_require__(7484));
|
||||
const uuid_1 = __nccwpck_require__(2048);
|
||||
const crypto_1 = __nccwpck_require__(6982);
|
||||
const utils = __importStar(__nccwpck_require__(9277));
|
||||
const CHERRYPICK_EMPTY = 'The previous cherry-pick is now empty, possibly due to conflict resolution.';
|
||||
const NOTHING_TO_COMMIT = 'nothing to commit, working tree clean';
|
||||
@@ -182,7 +182,7 @@ function createOrUpdateBranch(git, commitMessage, base, branch, branchRemoteName
|
||||
base = base ? base : workingBase;
|
||||
const baseRemote = 'origin';
|
||||
// Save the working base changes to a temporary branch
|
||||
const tempBranch = (0, uuid_1.v4)();
|
||||
const tempBranch = (0, crypto_1.randomUUID)();
|
||||
yield git.checkout(tempBranch, 'HEAD');
|
||||
// Commit any uncommitted changes
|
||||
if (yield git.isDirty(true, addPaths)) {
|
||||
@@ -1509,7 +1509,9 @@ class GitHubHelper {
|
||||
const isEventualConsistencyError = (e) => e instanceof request_error_1.RequestError &&
|
||||
e.status === 422 &&
|
||||
e.message.includes('Could not resolve to a node');
|
||||
const withRetryForNewPr = (fn) => pull.created ? utils.retryWithBackoff(fn, isEventualConsistencyError) : fn();
|
||||
const withRetryForNewPr = (fn) => pull.created
|
||||
? utils.retryWithBackoff(fn, isEventualConsistencyError)
|
||||
: fn();
|
||||
// Apply milestone
|
||||
if (inputs.milestone) {
|
||||
core.info(`Applying milestone '${inputs.milestone}'`);
|
||||
@@ -29227,687 +29229,6 @@ if (process.env.NODE_DEBUG && /\btunnel\b/.test(process.env.NODE_DEBUG)) {
|
||||
exports.debug = debug; // for test
|
||||
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 2048:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
Object.defineProperty(exports, "NIL", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _nil.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "parse", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _parse.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "stringify", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _stringify.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "v1", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _v.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "v3", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _v2.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "v4", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _v3.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "v5", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _v4.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "validate", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _validate.default;
|
||||
}
|
||||
}));
|
||||
Object.defineProperty(exports, "version", ({
|
||||
enumerable: true,
|
||||
get: function () {
|
||||
return _version.default;
|
||||
}
|
||||
}));
|
||||
|
||||
var _v = _interopRequireDefault(__nccwpck_require__(6415));
|
||||
|
||||
var _v2 = _interopRequireDefault(__nccwpck_require__(1697));
|
||||
|
||||
var _v3 = _interopRequireDefault(__nccwpck_require__(4676));
|
||||
|
||||
var _v4 = _interopRequireDefault(__nccwpck_require__(9771));
|
||||
|
||||
var _nil = _interopRequireDefault(__nccwpck_require__(7723));
|
||||
|
||||
var _version = _interopRequireDefault(__nccwpck_require__(5868));
|
||||
|
||||
var _validate = _interopRequireDefault(__nccwpck_require__(6200));
|
||||
|
||||
var _stringify = _interopRequireDefault(__nccwpck_require__(7597));
|
||||
|
||||
var _parse = _interopRequireDefault(__nccwpck_require__(7267));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 216:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _crypto = _interopRequireDefault(__nccwpck_require__(6982));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
function md5(bytes) {
|
||||
if (Array.isArray(bytes)) {
|
||||
bytes = Buffer.from(bytes);
|
||||
} else if (typeof bytes === 'string') {
|
||||
bytes = Buffer.from(bytes, 'utf8');
|
||||
}
|
||||
|
||||
return _crypto.default.createHash('md5').update(bytes).digest();
|
||||
}
|
||||
|
||||
var _default = md5;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 4221:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _crypto = _interopRequireDefault(__nccwpck_require__(6982));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
var _default = {
|
||||
randomUUID: _crypto.default.randomUUID
|
||||
};
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 7723:
|
||||
/***/ ((__unused_webpack_module, exports) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
var _default = '00000000-0000-0000-0000-000000000000';
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 7267:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _validate = _interopRequireDefault(__nccwpck_require__(6200));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
function parse(uuid) {
|
||||
if (!(0, _validate.default)(uuid)) {
|
||||
throw TypeError('Invalid UUID');
|
||||
}
|
||||
|
||||
let v;
|
||||
const arr = new Uint8Array(16); // Parse ########-....-....-....-............
|
||||
|
||||
arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24;
|
||||
arr[1] = v >>> 16 & 0xff;
|
||||
arr[2] = v >>> 8 & 0xff;
|
||||
arr[3] = v & 0xff; // Parse ........-####-....-....-............
|
||||
|
||||
arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8;
|
||||
arr[5] = v & 0xff; // Parse ........-....-####-....-............
|
||||
|
||||
arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8;
|
||||
arr[7] = v & 0xff; // Parse ........-....-....-####-............
|
||||
|
||||
arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8;
|
||||
arr[9] = v & 0xff; // Parse ........-....-....-....-############
|
||||
// (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes)
|
||||
|
||||
arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff;
|
||||
arr[11] = v / 0x100000000 & 0xff;
|
||||
arr[12] = v >>> 24 & 0xff;
|
||||
arr[13] = v >>> 16 & 0xff;
|
||||
arr[14] = v >>> 8 & 0xff;
|
||||
arr[15] = v & 0xff;
|
||||
return arr;
|
||||
}
|
||||
|
||||
var _default = parse;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 7879:
|
||||
/***/ ((__unused_webpack_module, exports) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
var _default = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 2973:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = rng;
|
||||
|
||||
var _crypto = _interopRequireDefault(__nccwpck_require__(6982));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate
|
||||
|
||||
let poolPtr = rnds8Pool.length;
|
||||
|
||||
function rng() {
|
||||
if (poolPtr > rnds8Pool.length - 16) {
|
||||
_crypto.default.randomFillSync(rnds8Pool);
|
||||
|
||||
poolPtr = 0;
|
||||
}
|
||||
|
||||
return rnds8Pool.slice(poolPtr, poolPtr += 16);
|
||||
}
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 507:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _crypto = _interopRequireDefault(__nccwpck_require__(6982));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
function sha1(bytes) {
|
||||
if (Array.isArray(bytes)) {
|
||||
bytes = Buffer.from(bytes);
|
||||
} else if (typeof bytes === 'string') {
|
||||
bytes = Buffer.from(bytes, 'utf8');
|
||||
}
|
||||
|
||||
return _crypto.default.createHash('sha1').update(bytes).digest();
|
||||
}
|
||||
|
||||
var _default = sha1;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 7597:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
exports.unsafeStringify = unsafeStringify;
|
||||
|
||||
var _validate = _interopRequireDefault(__nccwpck_require__(6200));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
/**
|
||||
* Convert array of 16 byte values to UUID string format of the form:
|
||||
* XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
|
||||
*/
|
||||
const byteToHex = [];
|
||||
|
||||
for (let i = 0; i < 256; ++i) {
|
||||
byteToHex.push((i + 0x100).toString(16).slice(1));
|
||||
}
|
||||
|
||||
function unsafeStringify(arr, offset = 0) {
|
||||
// Note: Be careful editing this code! It's been tuned for performance
|
||||
// and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434
|
||||
return byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]];
|
||||
}
|
||||
|
||||
function stringify(arr, offset = 0) {
|
||||
const uuid = unsafeStringify(arr, offset); // Consistency check for valid UUID. If this throws, it's likely due to one
|
||||
// of the following:
|
||||
// - One or more input array values don't map to a hex octet (leading to
|
||||
// "undefined" in the uuid)
|
||||
// - Invalid input values for the RFC `version` or `variant` fields
|
||||
|
||||
if (!(0, _validate.default)(uuid)) {
|
||||
throw TypeError('Stringified UUID is invalid');
|
||||
}
|
||||
|
||||
return uuid;
|
||||
}
|
||||
|
||||
var _default = stringify;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 6415:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _rng = _interopRequireDefault(__nccwpck_require__(2973));
|
||||
|
||||
var _stringify = __nccwpck_require__(7597);
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
// **`v1()` - Generate time-based UUID**
|
||||
//
|
||||
// Inspired by https://github.com/LiosK/UUID.js
|
||||
// and http://docs.python.org/library/uuid.html
|
||||
let _nodeId;
|
||||
|
||||
let _clockseq; // Previous uuid creation time
|
||||
|
||||
|
||||
let _lastMSecs = 0;
|
||||
let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details
|
||||
|
||||
function v1(options, buf, offset) {
|
||||
let i = buf && offset || 0;
|
||||
const b = buf || new Array(16);
|
||||
options = options || {};
|
||||
let node = options.node || _nodeId;
|
||||
let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not
|
||||
// specified. We do this lazily to minimize issues related to insufficient
|
||||
// system entropy. See #189
|
||||
|
||||
if (node == null || clockseq == null) {
|
||||
const seedBytes = options.random || (options.rng || _rng.default)();
|
||||
|
||||
if (node == null) {
|
||||
// Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1)
|
||||
node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]];
|
||||
}
|
||||
|
||||
if (clockseq == null) {
|
||||
// Per 4.2.2, randomize (14 bit) clockseq
|
||||
clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff;
|
||||
}
|
||||
} // UUID timestamps are 100 nano-second units since the Gregorian epoch,
|
||||
// (1582-10-15 00:00). JSNumbers aren't precise enough for this, so
|
||||
// time is handled internally as 'msecs' (integer milliseconds) and 'nsecs'
|
||||
// (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00.
|
||||
|
||||
|
||||
let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock
|
||||
// cycle to simulate higher resolution clock
|
||||
|
||||
let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs)
|
||||
|
||||
const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression
|
||||
|
||||
if (dt < 0 && options.clockseq === undefined) {
|
||||
clockseq = clockseq + 1 & 0x3fff;
|
||||
} // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new
|
||||
// time interval
|
||||
|
||||
|
||||
if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) {
|
||||
nsecs = 0;
|
||||
} // Per 4.2.1.2 Throw error if too many uuids are requested
|
||||
|
||||
|
||||
if (nsecs >= 10000) {
|
||||
throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");
|
||||
}
|
||||
|
||||
_lastMSecs = msecs;
|
||||
_lastNSecs = nsecs;
|
||||
_clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch
|
||||
|
||||
msecs += 12219292800000; // `time_low`
|
||||
|
||||
const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000;
|
||||
b[i++] = tl >>> 24 & 0xff;
|
||||
b[i++] = tl >>> 16 & 0xff;
|
||||
b[i++] = tl >>> 8 & 0xff;
|
||||
b[i++] = tl & 0xff; // `time_mid`
|
||||
|
||||
const tmh = msecs / 0x100000000 * 10000 & 0xfffffff;
|
||||
b[i++] = tmh >>> 8 & 0xff;
|
||||
b[i++] = tmh & 0xff; // `time_high_and_version`
|
||||
|
||||
b[i++] = tmh >>> 24 & 0xf | 0x10; // include version
|
||||
|
||||
b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant)
|
||||
|
||||
b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low`
|
||||
|
||||
b[i++] = clockseq & 0xff; // `node`
|
||||
|
||||
for (let n = 0; n < 6; ++n) {
|
||||
b[i + n] = node[n];
|
||||
}
|
||||
|
||||
return buf || (0, _stringify.unsafeStringify)(b);
|
||||
}
|
||||
|
||||
var _default = v1;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 1697:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _v = _interopRequireDefault(__nccwpck_require__(2930));
|
||||
|
||||
var _md = _interopRequireDefault(__nccwpck_require__(216));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
const v3 = (0, _v.default)('v3', 0x30, _md.default);
|
||||
var _default = v3;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 2930:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports.URL = exports.DNS = void 0;
|
||||
exports["default"] = v35;
|
||||
|
||||
var _stringify = __nccwpck_require__(7597);
|
||||
|
||||
var _parse = _interopRequireDefault(__nccwpck_require__(7267));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
function stringToBytes(str) {
|
||||
str = unescape(encodeURIComponent(str)); // UTF8 escape
|
||||
|
||||
const bytes = [];
|
||||
|
||||
for (let i = 0; i < str.length; ++i) {
|
||||
bytes.push(str.charCodeAt(i));
|
||||
}
|
||||
|
||||
return bytes;
|
||||
}
|
||||
|
||||
const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8';
|
||||
exports.DNS = DNS;
|
||||
const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8';
|
||||
exports.URL = URL;
|
||||
|
||||
function v35(name, version, hashfunc) {
|
||||
function generateUUID(value, namespace, buf, offset) {
|
||||
var _namespace;
|
||||
|
||||
if (typeof value === 'string') {
|
||||
value = stringToBytes(value);
|
||||
}
|
||||
|
||||
if (typeof namespace === 'string') {
|
||||
namespace = (0, _parse.default)(namespace);
|
||||
}
|
||||
|
||||
if (((_namespace = namespace) === null || _namespace === void 0 ? void 0 : _namespace.length) !== 16) {
|
||||
throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)');
|
||||
} // Compute hash of namespace and value, Per 4.3
|
||||
// Future: Use spread syntax when supported on all platforms, e.g. `bytes =
|
||||
// hashfunc([...namespace, ... value])`
|
||||
|
||||
|
||||
let bytes = new Uint8Array(16 + value.length);
|
||||
bytes.set(namespace);
|
||||
bytes.set(value, namespace.length);
|
||||
bytes = hashfunc(bytes);
|
||||
bytes[6] = bytes[6] & 0x0f | version;
|
||||
bytes[8] = bytes[8] & 0x3f | 0x80;
|
||||
|
||||
if (buf) {
|
||||
offset = offset || 0;
|
||||
|
||||
for (let i = 0; i < 16; ++i) {
|
||||
buf[offset + i] = bytes[i];
|
||||
}
|
||||
|
||||
return buf;
|
||||
}
|
||||
|
||||
return (0, _stringify.unsafeStringify)(bytes);
|
||||
} // Function#name is not settable on some platforms (#270)
|
||||
|
||||
|
||||
try {
|
||||
generateUUID.name = name; // eslint-disable-next-line no-empty
|
||||
} catch (err) {} // For CommonJS default export support
|
||||
|
||||
|
||||
generateUUID.DNS = DNS;
|
||||
generateUUID.URL = URL;
|
||||
return generateUUID;
|
||||
}
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 4676:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _native = _interopRequireDefault(__nccwpck_require__(4221));
|
||||
|
||||
var _rng = _interopRequireDefault(__nccwpck_require__(2973));
|
||||
|
||||
var _stringify = __nccwpck_require__(7597);
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
function v4(options, buf, offset) {
|
||||
if (_native.default.randomUUID && !buf && !options) {
|
||||
return _native.default.randomUUID();
|
||||
}
|
||||
|
||||
options = options || {};
|
||||
|
||||
const rnds = options.random || (options.rng || _rng.default)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`
|
||||
|
||||
|
||||
rnds[6] = rnds[6] & 0x0f | 0x40;
|
||||
rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided
|
||||
|
||||
if (buf) {
|
||||
offset = offset || 0;
|
||||
|
||||
for (let i = 0; i < 16; ++i) {
|
||||
buf[offset + i] = rnds[i];
|
||||
}
|
||||
|
||||
return buf;
|
||||
}
|
||||
|
||||
return (0, _stringify.unsafeStringify)(rnds);
|
||||
}
|
||||
|
||||
var _default = v4;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 9771:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _v = _interopRequireDefault(__nccwpck_require__(2930));
|
||||
|
||||
var _sha = _interopRequireDefault(__nccwpck_require__(507));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
const v5 = (0, _v.default)('v5', 0x50, _sha.default);
|
||||
var _default = v5;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 6200:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _regex = _interopRequireDefault(__nccwpck_require__(7879));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
function validate(uuid) {
|
||||
return typeof uuid === 'string' && _regex.default.test(uuid);
|
||||
}
|
||||
|
||||
var _default = validate;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 5868:
|
||||
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
||||
|
||||
"use strict";
|
||||
|
||||
|
||||
Object.defineProperty(exports, "__esModule", ({
|
||||
value: true
|
||||
}));
|
||||
exports["default"] = void 0;
|
||||
|
||||
var _validate = _interopRequireDefault(__nccwpck_require__(6200));
|
||||
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
|
||||
function version(uuid) {
|
||||
if (!(0, _validate.default)(uuid)) {
|
||||
throw TypeError('Invalid UUID');
|
||||
}
|
||||
|
||||
return parseInt(uuid.slice(14, 15), 16);
|
||||
}
|
||||
|
||||
var _default = version;
|
||||
exports["default"] = _default;
|
||||
|
||||
/***/ }),
|
||||
|
||||
/***/ 2613:
|
||||
@@ -36828,6 +36149,9 @@ function validateConcurrency(concurrency) {
|
||||
/******/ __nccwpck_require__.m = __webpack_modules__;
|
||||
/******/
|
||||
/************************************************************************/
|
||||
/******/ /* webpack/runtime/asset-relocator-loader */
|
||||
/******/ if (typeof __nccwpck_require__ !== 'undefined') __nccwpck_require__.ab = __dirname + "/";
|
||||
/******/
|
||||
/******/ /* webpack/runtime/create fake namespace object */
|
||||
/******/ (() => {
|
||||
/******/ var getProto = Object.getPrototypeOf ? (obj) => (Object.getPrototypeOf(obj)) : (obj) => (obj.__proto__);
|
||||
@@ -36908,10 +36232,6 @@ function validateConcurrency(concurrency) {
|
||||
/******/ };
|
||||
/******/ })();
|
||||
/******/
|
||||
/******/ /* webpack/runtime/compat */
|
||||
/******/
|
||||
/******/ if (typeof __nccwpck_require__ !== 'undefined') __nccwpck_require__.ab = __dirname + "/";
|
||||
/******/
|
||||
/******/ /* webpack/runtime/require chunk loading */
|
||||
/******/ (() => {
|
||||
/******/ // no baseURI
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ module.exports = {
|
||||
moduleFileExtensions: ['js', 'ts'],
|
||||
testEnvironment: 'node',
|
||||
testMatch: ['**/*.test.ts'],
|
||||
testRunner: 'jest-circus/runner',
|
||||
|
||||
transform: {
|
||||
'^.+\\.ts$': 'ts-jest'
|
||||
},
|
||||
|
||||
Generated
+2447
-1667
File diff suppressed because it is too large
Load Diff
+10
-12
@@ -41,28 +41,26 @@
|
||||
"@octokit/plugin-throttling": "^9.6.1",
|
||||
"@octokit/request-error": "^6.1.8",
|
||||
"node-fetch-native": "^1.6.7",
|
||||
"p-limit": "^6.2.0",
|
||||
"uuid": "^9.0.1"
|
||||
"p-limit": "^6.2.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/jest": "^29.5.14",
|
||||
"@types/jest": "^30.0.0",
|
||||
"@types/node": "^18.19.130",
|
||||
"@typescript-eslint/eslint-plugin": "^7.18.0",
|
||||
"@typescript-eslint/parser": "^7.18.0",
|
||||
"@vercel/ncc": "^0.38.4",
|
||||
"@vercel/ncc": "^0.45.0",
|
||||
"eslint": "^8.57.1",
|
||||
"eslint-import-resolver-typescript": "^3.10.1",
|
||||
"eslint-plugin-github": "^4.10.2",
|
||||
"eslint-plugin-import": "^2.32.0",
|
||||
"eslint-plugin-jest": "^27.9.0",
|
||||
"eslint-plugin-prettier": "^5.5.5",
|
||||
"jest": "^29.7.0",
|
||||
"jest-circus": "^29.7.0",
|
||||
"jest-environment-jsdom": "^30.3.0",
|
||||
"js-yaml": "^4.1.1",
|
||||
"prettier": "^3.8.1",
|
||||
"ts-jest": "^29.4.9",
|
||||
"eslint-plugin-prettier": "^5.5.6",
|
||||
"jest": "^30.5.0",
|
||||
"jest-environment-jsdom": "^30.5.0",
|
||||
"js-yaml": "^5.4.1",
|
||||
"prettier": "^3.9.6",
|
||||
"ts-jest": "^29.4.12",
|
||||
"typescript": "^5.9.3",
|
||||
"undici": "^6.24.1"
|
||||
"undici": "^6.29.0"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import * as core from '@actions/core'
|
||||
import {randomUUID} from 'crypto'
|
||||
import {GitCommandManager, Commit} from './git-command-manager'
|
||||
import {v4 as uuidv4} from 'uuid'
|
||||
import * as utils from './utils'
|
||||
|
||||
const CHERRYPICK_EMPTY =
|
||||
@@ -189,7 +189,7 @@ export async function createOrUpdateBranch(
|
||||
const baseRemote = 'origin'
|
||||
|
||||
// Save the working base changes to a temporary branch
|
||||
const tempBranch = uuidv4()
|
||||
const tempBranch = randomUUID()
|
||||
await git.checkout(tempBranch, 'HEAD')
|
||||
// Commit any uncommitted changes
|
||||
if (await git.isDirty(true, addPaths)) {
|
||||
|
||||
Reference in New Issue
Block a user