Skip to content

Commit b9ebcf1

Browse files
committed
Config git user before commit
1 parent 24ff207 commit b9ebcf1

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

.github/workflows/main.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,6 @@ jobs:
1717
- uses: actions/setup-node@v6
1818
with:
1919
node-version: "24"
20-
- name: configure git
21-
run: |
22-
git config --global user.email "[email protected]"
23-
git config --global user.name "GitHub Actions"
2420
- run: yarn
2521
- run: yarn execute
2622
env:

src/utilities.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,16 @@ export const commitChanges = async (directory: string, message: string) => {
7979

8080
await spawn("git", ["add", "."], { cwd: directory });
8181

82+
await spawn(
83+
"git",
84+
["config", "set", "user.email", "[email protected]"],
85+
{ cwd: directory },
86+
);
87+
await spawn(
88+
"git",
89+
["config", "set", "user.name", "prettier-regression-testing"],
90+
{ cwd: directory },
91+
);
8292
await spawn(
8393
"git",
8494
["commit", "--allow-empty", "--no-verify", "-m", message],

0 commit comments

Comments
 (0)