Release 0.0.3
This commit is contained in:
@@ -2,7 +2,7 @@ import { analyzeStorage } from "../core/analyzer.js";
|
||||
import { isMediaPath, normalizePath } from "../core/path-utils.js";
|
||||
|
||||
async function* walkFilePicker(storage, target = "", onProgress = null) {
|
||||
onProgress?.({ phase: "files", label: `Durchsuche ${storage}:${target || "/"}` });
|
||||
onProgress?.({ phase: "files", label: format("KSA.Progress.BrowseStorage", { storage, path: target || "/" }) });
|
||||
const result = await FilePicker.browse(storage, target);
|
||||
for (const file of result.files ?? []) {
|
||||
const path = normalizePath(file);
|
||||
@@ -78,7 +78,7 @@ async function* packagePackEntries(onProgress = null) {
|
||||
const ownerType = pack.metadata.packageType;
|
||||
const ownerId = pack.metadata.packageName;
|
||||
if (!["module", "system"].includes(ownerType) || !ownerId) continue;
|
||||
onProgress?.({ phase: "sources", label: `Lese Paket-Pack ${pack.collection}`, currentSource: pack.collection });
|
||||
onProgress?.({ phase: "sources", label: format("KSA.Progress.ReadPack", { pack: pack.collection }), currentSource: pack.collection });
|
||||
const documents = await pack.getDocuments();
|
||||
for (const document of documents) {
|
||||
yield {
|
||||
@@ -108,3 +108,7 @@ export async function runRuntimeAnalysis({ onProgress }={}) {
|
||||
onProgress
|
||||
});
|
||||
}
|
||||
|
||||
function format(key, data) {
|
||||
return game.i18n?.format(key, data) ?? key;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user