Skip to content

Commit a7c968e

Browse files
bump turbo (#19179)
The Bun build issue was caused by Turborepo passing through `USERPROFILE` from the env. Probably need to file a bug with Bun: ``` Works: env: USERPROFILE: undefined CWD: `D:\a\tailwindcss\tailwindcss\packages\@tailwindcss-standalone` Fails: env: USERPROFILE: "C:\Users\runneradmin" CWD: `D:\a\tailwindcss\tailwindcss\packages\@tailwindcss-standalone` ```
1 parent e4b6c67 commit a7c968e

File tree

5 files changed

+38
-49
lines changed

5 files changed

+38
-49
lines changed

integrations/upgrade/index.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2818,7 +2818,7 @@ test(
28182818
`,
28192819
},
28202820
},
2821-
async ({ exec, fs, expect }) => {
2821+
async ({ exec, root, fs, expect }) => {
28222822
await exec('npx @tailwindcss/upgrade')
28232823
28242824
let before = await fs.dumpFiles('./src/**/*.{css,html}')
@@ -2855,7 +2855,7 @@ test(
28552855
`)
28562856
28572857
// Commit the changes
2858-
if (isRepoDirty()) {
2858+
if (isRepoDirty(root)) {
28592859
await exec('git add .')
28602860
await exec('git commit -m "upgrade"')
28612861
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
"prettier-plugin-embed": "^0.5.0",
5757
"prettier-plugin-organize-imports": "^4.3.0",
5858
"tsup": "^8.5.0",
59-
"turbo": "^2.5.4",
59+
"turbo": "^2.6.1",
6060
"typescript": "^5.5.4",
6161
"vitest": "^2.0.5"
6262
},

packages/@tailwindcss-standalone/scripts/build.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ async function buildForPlatform(triple: string, outfile: string) {
1616
// statically bundle the proper binaries for musl vs glibc
1717
cmd = cmd.env({
1818
PLATFORM_LIBC: triple.includes('-musl') ? 'musl' : 'glibc',
19+
20+
// Workaround for Bun binary downloads failing on Windows CI when
21+
// USERPROFILE is passed through by Turborepo.
22+
USERPROFILE: '',
1923
})
2024

2125
return await cmd

packages/@tailwindcss-upgrade/src/utils/git.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import { execSync } from 'node:child_process'
22

3-
export function isRepoDirty() {
3+
export function isRepoDirty(cwd?: string) {
44
try {
5-
let stdout = execSync('git status --porcelain', { encoding: 'utf-8' })
5+
let stdout = execSync('git status --porcelain', { encoding: 'utf-8', cwd })
66
return stdout.trim() !== ''
77
} catch (error) {
88
// If it's not a git repository we don't know if it's dirty or not. But we

pnpm-lock.yaml

Lines changed: 29 additions & 44 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)