mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-17 09:36:08 +08:00
ui: ensure build cache
This commit is contained in:
1 parent
da09cdbc84
commit
20bbda794e
2 files changed
+8
-3
No files matched your search
@@ -35,10 +35,9 @@ jobs:
|
||||
yarn.lock
|
||||
.cache
|
||||
**/tsconfig.tsbuildinfo
|
||||
key: ${{ github.ref }}
|
||||
key: cache-${{ github.ref }}
|
||||
restore-keys: |
|
||||
master
|
||||
main
|
||||
cache-
|
||||
- name: Config And Install
|
||||
run: |
|
||||
[[ ! -z "${{secrets.NPM_TOKEN}}" ]] && echo "npmAuthToken: ${{secrets.NPM_TOKEN}}" >> .yarnrc.yml
|
||||
|
||||
@@ -82,6 +82,9 @@ export default function (env: { production?: boolean, measure?: boolean } = {})
|
||||
type: 'filesystem',
|
||||
cacheDirectory: root('../../.cache'),
|
||||
idleTimeout: 30000,
|
||||
buildDependencies: {
|
||||
config: [__filename],
|
||||
},
|
||||
},
|
||||
output: {
|
||||
path: root('public'),
|
||||
@@ -236,6 +239,9 @@ export default function (env: { production?: boolean, measure?: boolean } = {})
|
||||
new webpack.DefinePlugin({
|
||||
'process.env.VERSION': JSON.stringify(require('@hydrooj/ui-default/package.json').version),
|
||||
}),
|
||||
new webpack.optimize.MinChunkSizePlugin({
|
||||
minChunkSize: 128000,
|
||||
}),
|
||||
new webpack.NormalModuleReplacementPlugin(/\/(vscode-)?nls\.js/, require.resolve('../../components/monaco/nls')),
|
||||
new MonacoWebpackPlugin({
|
||||
filename: '[name].[hash:10].worker.js',
|
||||
|
||||
Reference in new issue
Block a user