1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-07-06 23:56:13 +02:00

Chore: Apply changes from mobile plugins to lib/ and app-desktop/ (#10079)

This commit is contained in:
Henry Heino
2024-03-09 03:03:57 -08:00
committed by GitHub
parent 91004f5714
commit 25cd5affca
37 changed files with 418 additions and 205 deletions

View File

@ -68,6 +68,10 @@ export default class RepositoryApi {
this.tempDir_ = tempDir;
}
public static ofDefaultJoplinRepo(tempDirPath: string) {
return new RepositoryApi('https://github.com/joplin/plugins', tempDirPath);
}
public async initialize() {
// https://github.com/joplin/plugins
// https://api.github.com/repos/joplin/plugins/releases
@ -183,6 +187,12 @@ export default class RepositoryApi {
}
}
output.sort((m1, m2) => {
if (m1._recommended && !m2._recommended) return -1;
if (!m1._recommended && m2._recommended) return +1;
return m1.name.toLowerCase() < m2.name.toLowerCase() ? -1 : +1;
});
return output;
}