|
51 | 51 | uses: actions/checkout@v6 |
52 | 52 | with: |
53 | 53 | repository: meshery/meshery |
| 54 | + # Pin to last known-good commit before the @mui/x-tree-view v8 upgrade |
| 55 | + # that broke the TreeView import (meshery/meshery#18163). |
| 56 | + # Update this ref once Meshery UI fixes the migration. |
| 57 | + ref: 7c3d02c91365dc776b11ffc50aab277026e86701 |
54 | 58 | path: meshery |
55 | 59 | fetch-depth: 1 |
56 | 60 |
|
|
62 | 66 | working-directory: meshery/ui |
63 | 67 | run: npm install ../../sistent/${{ env.SISTENT_PACKAGE }} |
64 | 68 |
|
65 | | - - name: Patch Meshery UI for Next.js 16.x compatibility |
66 | | - working-directory: meshery/ui |
67 | | - run: | |
68 | | - # Add ignoreDeprecations for TypeScript 6.x baseUrl deprecation |
69 | | - if [ -f tsconfig.json ] && grep -q '"baseUrl"' tsconfig.json && ! grep -q '"ignoreDeprecations"' tsconfig.json; then |
70 | | - sed -i 's/"compilerOptions"\s*:\s*{/"compilerOptions": {\n "ignoreDeprecations": "6.0",/' tsconfig.json |
71 | | - echo "Patched tsconfig.json to add ignoreDeprecations: 6.0" |
72 | | - fi |
73 | | - # Patch package.json build script to use --webpack for Next.js 16 compatibility |
74 | | - if [ -f package.json ] && grep -q '"build"' package.json && ! grep -q -- '--webpack' package.json; then |
75 | | - node -e " |
76 | | - const fs = require('fs'); |
77 | | - const pkg = JSON.parse(fs.readFileSync('package.json', 'utf8')); |
78 | | - if (pkg.scripts && pkg.scripts.build) { |
79 | | - pkg.scripts.build = pkg.scripts.build.replace('next build', 'next build --webpack'); |
80 | | - fs.writeFileSync('package.json', JSON.stringify(pkg, null, 2)); |
81 | | - console.log('Patched build script to use webpack mode'); |
82 | | - } |
83 | | - " |
84 | | - fi |
85 | | -
|
86 | 69 | - name: Build Meshery UI |
87 | 70 | working-directory: meshery/ui |
88 | 71 | run: | |
|
0 commit comments