This is an automated email from the ASF dual-hosted git repository.
kassiez pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris-website.git
The following commit(s) were added to refs/heads/master by this push:
new 226c5b979d5 Correct workerjs path (#1965)
226c5b979d5 is described below
commit 226c5b979d5cf09bfcf141e78909c583d140ac06
Author: yangon <[email protected]>
AuthorDate: Wed Feb 5 18:02:30 2025 +0800
Correct workerjs path (#1965)
---
.github/workflows/cron-deploy-website.yml | 2 +-
.github/workflows/manual-deploy-website.yml | 1 -
scripts/update_search_hash.js | 2 +-
3 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/.github/workflows/cron-deploy-website.yml
b/.github/workflows/cron-deploy-website.yml
index eeb1105444e..b3c16481ebc 100644
--- a/.github/workflows/cron-deploy-website.yml
+++ b/.github/workflows/cron-deploy-website.yml
@@ -37,8 +37,8 @@ jobs:
npm install -g yarn
yarn cache clean
export NODE_OPTIONS=--max-old-space-size=8192
- yarn && yarn build
node ./scripts/update_search_hash.js
+ yarn && yarn build
touch build/.dummy
cp .asf-site.yaml ./build/.asf.yaml
cp versions.json ./build/
diff --git a/.github/workflows/manual-deploy-website.yml
b/.github/workflows/manual-deploy-website.yml
index 4114cdf175d..9aba078446e 100644
--- a/.github/workflows/manual-deploy-website.yml
+++ b/.github/workflows/manual-deploy-website.yml
@@ -45,7 +45,6 @@ jobs:
touch build/.dummy
cp .asf-site.yaml ./build/.asf.yaml
cp versions.json ./build/
- cp worker.js ./build/
cp .htaccess ./build/
ls build
export DORIS_COMMIT=`git rev-parse HEAD`
diff --git a/scripts/update_search_hash.js b/scripts/update_search_hash.js
index 3e500661858..79aa349c199 100644
--- a/scripts/update_search_hash.js
+++ b/scripts/update_search_hash.js
@@ -30,7 +30,7 @@ searchConfig.docsDir = searchConfig.docsDir.map(dir =>
path.join(__dirname, `../
searchConfig.blogDir = searchConfig.blogDir.map(dir => path.join(__dirname,
`../${dir}`));
const searchHash = getIndexHash(searchConfig);
if (searchHash) {
- const workerJSPath = path.join(__dirname, '../worker.js');
+ const workerJSPath = path.join(__dirname,
'../src/theme/SearchBar/worker.js');
const workerJs = fs.readFileSync(workerJSPath, 'utf-8');
const targetRegex = /const searchIndexUrl =
"search-index\{dir\}\.json\?_=[^"]+"/;
const replacement = `const searchIndexUrl =
"search-index{dir}.json?_=${searchHash}"`;
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]