Browse Source

Update SW

master
186526 9 months ago
parent
commit
defd333de7
Signed by: 186526 GPG Key ID: C7EB1E6B8CC5E51D
3 changed files with 15 additions and 2 deletions
  1. 11
      cleancache.js
  2. 4
      package.json
  3. 2
      source/_data/links.yml

11
cleancache.js

@ -0,0 +1,11 @@
var fetch = require('node-fetch');
fetch('https://api.cloudflare.com/client/v4/zones/a39ebcbe4e56a2e7f32867f988bde7df/purge_cache', {
method: 'POST',
headers: {
//'X-Auth-Email': '[email protected]',
'Authorization': ' Bearer ALz3Oq3tley5eJ9JBJ6nj6MHTsmLRWUyxhK29_QJ',
'Content-Type': 'application/json'
},
body: JSON.stringify({"purge_everything":true})
});

4
package.json

@ -7,7 +7,8 @@
"clean": "hexo clean",
"deploy": "hexo deploy",
"server": "hexo server",
"build-cloudflare": "yarn;yarn --cwd ./themes/suka --production;hexo generate"
"build-cloudflare": "yarn;yarn --cwd ./themes/suka --production;hexo generate;node cleancache.js",
"vercel-build": "yarn build-cloudflare"
},
"hexo": {
"version": "5.3.0"
@ -29,6 +30,7 @@
"hexo-server": "^2.0.0",
"hexo-theme-landscape": "^0.0.3",
"hexo-uglify": "^2.0.0",
"node-fetch": "^2.6.1",
"spectre.css": "^0.5.9",
"yarn": "^1.22.10"
}

2
source/_data/links.yml

@ -10,7 +10,7 @@
url: "https://www.lbyxlz.com"
img: "https://gitee.com/lbyxlz_admin/xlzpic/raw/master/images/2021/02/18/76640ed89300d851fd5652ac627896bf.jpg"
text: "优质软件&教程分享"
"Puresys纯净系统-软件下载":
"Puresys":
url: "https://www.puresys.net"
img: "https://gitee.com/clamowo/CLAMOWO/raw/master/img/%E5%A4%B4%E5%83%8F.jpg"
"申请友链":
Loading…
Cancel
Save