show progress for imports and deletions
This commit is contained in:
parent
38eea05789
commit
5e342b6fe5
13 changed files with 343 additions and 115 deletions
|
|
@ -58,7 +58,9 @@ const DIRS = {
|
|||
// the bundle does not ship (user-added languages) are left untouched.
|
||||
function filesDiffer(a, b) {
|
||||
try {
|
||||
return !fs.readFileSync(a).equals(fs.readFileSync(b))
|
||||
// compare as text on purpose: Buffer.equals() throws on a string, and that
|
||||
// throw was read as "differs", so every boot recopied every translation
|
||||
return fs.readFileSync(a, 'utf8') !== fs.readFileSync(b, 'utf8')
|
||||
} catch {
|
||||
return true // target missing/unreadable -> needs a (re)copy
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue