This commit is contained in:
tree 2023-04-26 03:15:06 +02:00
rodič 5c02c872f6
revize 929f2c4576
3 změnil soubory, kde provedl 7 přidání a 9 odebrání

Zobrazit soubor

@ -225,7 +225,7 @@ class DeConf_Collection {
}); });
} }
} }
for (let sg of data.index.segments) { for (const sg of data.index.segments) {
if (sg.remote) { if (sg.remote) {
continue; continue;
} }
@ -260,7 +260,6 @@ class DeConf_Collection {
} }
async optimizeImages() { async optimizeImages() {
let base = {};
for (const as of this.assets) { for (const as of this.assets) {
if (this.data.index[as]) { if (this.data.index[as]) {
await this.optimizeImageFile(this.data.index[as]); await this.optimizeImageFile(this.data.index[as]);
@ -334,10 +333,10 @@ class DeConf_Collection {
//await _imageOptimalizedWrite(tmpfile, fn); //await _imageOptimalizedWrite(tmpfile, fn);
console.log(`${fn} writed`); console.log(`${fn} writed`);
const sizes = [150, 300, 500]; /*const sizes = [150, 300, 500];
for (const sz of sizes) { for (const sz of sizes) {
console; console;
} }*/
sp.photo = ["photos", "speakers", ffn].join("/"); sp.photo = ["photos", "speakers", ffn].join("/");
} }

Zobrazit soubor

@ -3,16 +3,16 @@ import { DeConfEngine } from "./engine.js";
const deconf = new DeConfEngine(); const deconf = new DeConfEngine();
await deconf.init(); await deconf.init();
let cmd = Deno.args[0] || "build"; const cmd = Deno.args[0] || "build";
let args = Deno.args.slice(1) || []; const args = Deno.args.slice(1) || [];
const options = Object.fromEntries( /*const options = Object.fromEntries(
args.map((x) => { args.map((x) => {
const [key, value] = x.split("="); const [key, value] = x.split("=");
if (!value) return null; if (!value) return null;
return [key, value]; return [key, value];
}).filter((x) => x), }).filter((x) => x),
); );*/
const output = await deconf[cmd](...args); const output = await deconf[cmd](...args);
if (output) { if (output) {

Zobrazit soubor

@ -9,7 +9,6 @@ export async function loadJSONUrl(url, options) {
} }
export async function loadHtmlUrl(url) { export async function loadHtmlUrl(url) {
const cacheTimeout = 3600;
await ensureDir(CACHE_DIR); await ensureDir(CACHE_DIR);
const hash = Array.from( const hash = Array.from(
new Uint8Array( new Uint8Array(