换系统
This commit is contained in:
parent
1be20ea269
commit
a3a4991dd1
@ -20,3 +20,4 @@ async function downloadFile(url, filepath, name) {
|
||||
});
|
||||
}
|
||||
// downloadFile("https://www.cnblogs.com/images/logo_small.gif",__dirname + "/dow",'asd.gif')
|
||||
module.exports = downloadFile
|
@ -36,7 +36,7 @@ let gethtml = async (name, page) => {
|
||||
let getlist = async (name) => {
|
||||
let html;
|
||||
html = await gethtml(name, 1)
|
||||
console.log(html)
|
||||
console.log(JSON.stringify(html))
|
||||
return html;
|
||||
}
|
||||
getlist("偷星九月天")
|
||||
|
@ -2,9 +2,10 @@ const convert = require('webp-batch-convert');
|
||||
|
||||
|
||||
let webg = async (dir) => {
|
||||
console.log(dir)
|
||||
const cwebpOpts = {
|
||||
quiet: true, // 不输出详情
|
||||
q: 5 // 质量
|
||||
q: 1// 质量
|
||||
};
|
||||
// 清空输出目录
|
||||
// convert.utils.delDir(__dirname + '/webp');
|
||||
@ -15,4 +16,5 @@ let webg = async (dir) => {
|
||||
convert.utils.delDir(dir, /\.png$/);
|
||||
return res;
|
||||
}
|
||||
webg(__dirname + "\\img")
|
||||
module.exports = webg
|
Loading…
Reference in New Issue
Block a user