Load playlet lib as squashfs (#357)
* Load playlet lib as squashfs * typo
This commit is contained in:
1 parent
b534ea68db
commit
1cbb52fad4
6 files changed
+28
-14
No files matched your search
@@ -142,6 +142,9 @@ export class PlayletApi {
|
||||
static async setPlayletLibVersion(tag) {
|
||||
if (tag !== "") {
|
||||
const urls = [{
|
||||
link: `https://github.com/iBicha/playlet/releases/download/${tag}/playlet-lib.squashfs.pkg`,
|
||||
type: 'custom'
|
||||
}, {
|
||||
link: `https://github.com/iBicha/playlet/releases/download/${tag}/playlet-lib.zip`,
|
||||
type: 'custom'
|
||||
}]
|
||||
@@ -149,6 +152,9 @@ export class PlayletApi {
|
||||
// To avoid the "not found" error, we fallback to the default "latest" release.
|
||||
if (tag === "canary") {
|
||||
urls.push({
|
||||
link: `https://github.com/iBicha/playlet/releases/latest/download/playlet-lib.squashfs.pkg`,
|
||||
type: 'custom'
|
||||
}, {
|
||||
link: `https://github.com/iBicha/playlet/releases/latest/download/playlet-lib.zip`,
|
||||
type: 'custom'
|
||||
})
|
||||
|
||||
+8
-3
@@ -38,7 +38,9 @@
|
||||
const release = releases[i].name;
|
||||
if (
|
||||
libUrl ===
|
||||
`https://github.com/iBicha/playlet/releases/download/${release}/playlet-lib.zip`
|
||||
`https://github.com/iBicha/playlet/releases/download/${release}/playlet-lib.zip` ||
|
||||
libUrl ===
|
||||
`https://github.com/iBicha/playlet/releases/download/${release}/playlet-lib.squashfs.pkg`
|
||||
) {
|
||||
selectedRelease = release;
|
||||
break;
|
||||
@@ -55,8 +57,11 @@
|
||||
return {
|
||||
name: release.tag_name,
|
||||
enabled:
|
||||
release.assets.filter((asset) => asset.name === "playlet-lib.zip")
|
||||
.length > 0,
|
||||
release.assets.filter(
|
||||
(asset) =>
|
||||
asset.name === "playlet-lib.zip" ||
|
||||
asset.name === "playlet-lib.squashfs.pkg"
|
||||
).length > 0,
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user