Skip to content

Commit 1489efc

Browse files
committed
feat: Added completions for apt
1 parent 7d07f6e commit 1489efc

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
export default async function loadAptPackages(): Promise<string[]> {
2-
// Apt package enumeration requires parsing Packages.gz from a mirror
3-
// No simple public JSON API available - stub for now
4-
return []
2+
const response = await fetch('https://sources.debian.org/api/list')
3+
const data = await response.json() as { packages: { name: string }[] }
4+
return data.packages.map((p) => p.name)
55
}

0 commit comments

Comments
 (0)