hexo-theme-shokax 0.4.6 → 0.4.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hexo-theme-shokax",
3
- "version": "0.4.6",
3
+ "version": "0.4.7",
4
4
  "description": "a hexo theme based on shoka",
5
5
  "main": "index.js",
6
6
  "repository": "https://github.com/theme-shoka-x/hexo-theme-shokaX",
@@ -31,13 +31,12 @@
31
31
  "dependencies": {
32
32
  "@algolia/client-search": "^4.24.0",
33
33
  "@waline/client": "^3.2.6",
34
- "algoliasearch": "4.23.3",
35
- "esbuild": "^0.21.5",
36
- "hexo": "^7.2.0",
34
+ "algoliasearch": "4.24.0",
35
+ "esbuild": "^0.23.0",
36
+ "hexo": "^7.3.0",
37
37
  "hexo-algoliasearch": "^2.0.1",
38
38
  "hexo-feed": "^1.1.2",
39
39
  "hexo-fs": "^4.1.3",
40
- "hexo-lightning-minify": "^0.1.5",
41
40
  "hexo-pagination": "^3.0.0",
42
41
  "hexo-renderer-pug": "^3.0.0",
43
42
  "hexo-util": "^3.3.0",
@@ -1,16 +1,12 @@
1
1
  /*
2
2
  ShokaX ToolBox - Compiler
3
3
  compatibility: ShokaX v0.4.x
4
- NEED PNPM INSTALLED
5
4
  */
6
5
  import path from "node:path";
7
6
  import fs from 'fs/promises'
8
7
  import child_process from 'child_process'
9
- import {hoistDeps} from "./lib.mjs";
10
8
 
11
9
  const CONFIG = {
12
- depsHoist: true,
13
- minify: false,
14
10
  legacyScript: true,
15
11
  }
16
12
 
@@ -46,10 +42,10 @@ if (CONFIG.legacyScript) {
46
42
  } else if (sPath.startsWith('file:\\')) {
47
43
  sPath = sPath.slice(8); // 去除 'file:\'
48
44
  }
49
- child_process.exec('pnpm install',{
45
+ child_process.exec('npm install',{
50
46
  cwd: path.join(sPath,'./../')
51
47
  }, (code, stdout, stderr) => {
52
- child_process.exec('pnpm --package=typescript dlx tsc --build'.trim(), {
48
+ child_process.exec('"yes" | npx -p typescript tsc --build'.trim(), {
53
49
  cwd: sPath
54
50
  }, async (code, stdout, stderr) => {
55
51
  console.log('Deleting typescript files...')
@@ -61,15 +57,6 @@ if (CONFIG.legacyScript) {
61
57
  throw Error('Not implemented yet.')
62
58
  }
63
59
 
64
- if (CONFIG.depsHoist) {
65
- try {
66
- await hoistDeps()
67
- console.log('Finished hoisting dependencies.')
68
- } catch (e) {
69
- console.log('Skipping hoisting dependencies.')
70
- }
71
- }
72
-
73
60
  console.log('Done.')
74
61
 
75
62