Skip to content

Commit 8389af8

Browse files
committed
winget-source: sync newer manifests first
1 parent 96b834b commit 8389af8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

winget-source/sync-repo.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ syncFile('source.msix').then(async updated => {
3232

3333
db.all('SELECT * FROM pathparts', (error, rows) => {
3434
const pathparts = buildPathpartMap(error, rows);
35-
db.all('SELECT pathpart FROM manifest', (error, rows) => {
35+
db.all('SELECT pathpart FROM manifest ORDER BY rowid DESC', (error, rows) => {
3636
db.close();
3737
const uris = buildURIList(error, rows, pathparts);
3838
async.eachLimit(uris, parallelLimit, syncFile, (error) => {

winget-source/utilities.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,8 +222,8 @@ export async function syncFile(uri) {
222222
}
223223
}
224224
}
225-
const response = await fetch(remoteURL);
226225
winston.verbose(`downloading from ${remoteURL}`);
226+
const response = await fetch(remoteURL);
227227
await writeFile(localPath, response.body);
228228
const lastModified = getLastModifiedDate(response);
229229
if (lastModified) {

0 commit comments

Comments
 (0)