Files
com.blitzwallet/create-files-list.js
T
Blake KaufmanandGitHub 9369939ce4 68 translations (#140)
* created progress tracking file

* buildint json + translating vpn app pages

* finsihed all apps pages

* updated more translations

* contact page tranlations

* updating contact pages + send pages + receive pages + starting settings pages

* translating settings pages + making sure functions dont need to be translated

* finishing translations

* fix translation + import bugs

* removing empty translations

* fixing translations bugs

* missed learn more on about page

* adding select language page to onboarding

* missed translations

* fixing send page fee info text

* width of dropdown bug
2025-08-18 09:51:56 -04:00

43 lines
1.1 KiB
JavaScript

import fs from 'fs';
import path from 'path';
function getAllFiles(dirPath, arrayOfFiles = [], ignoreFolders = []) {
const files = fs.readdirSync(dirPath);
files.forEach(file => {
const fullPath = path.join(dirPath, file);
if (fs.statSync(fullPath).isDirectory()) {
if (!ignoreFolders.includes(file)) {
getAllFiles(fullPath, arrayOfFiles, ignoreFolders);
}
} else {
arrayOfFiles.push(fullPath);
}
});
return arrayOfFiles;
}
const folderPath = './db'; // folder to scan
const ignoreFolders = ['assets', 'constants']; // folders to skip
const statusFile = './locales/translation-status.json';
const allFiles = getAllFiles(folderPath, [], ignoreFolders);
// Load existing status if it exists
let status = {};
if (fs.existsSync(statusFile)) {
status = JSON.parse(fs.readFileSync(statusFile, 'utf8'));
}
// Update status for all files
allFiles.forEach(file => {
status[file] = false;
});
// Save the updated status
fs.writeFileSync(statusFile, JSON.stringify(status, null, 2));
console.log(`✅ Translation status updated in ${statusFile}`);