signageos-cli
LOW
maintainer prochac
0 votes
scanned 2026-09-24 09:42:26.093386
Why flagged
Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.
Triggered rules
Low
Few votes, recently uploaded
zero_votes_recent
Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.
PKGBUILD
1
# Maintainer: Tomáš Karela Procházka <tomas.prochazka5d@gmail.com>
2
3
pkgname=signageos-cli
4
_npmname=@signageos/cli
5
_cmd=sos
6
pkgver=4.4.0
7
pkgrel=1
8
pkgdesc='signageOS command-line interface for developing applets and managing devices'
9
arch=('any')
10
url='https://github.com/signageos/cli'
11
license=('MIT')
12
depends=('nodejs>=20')
13
makedepends=('npm')
14
# AUR `sos` (sosreport) also installs /usr/bin/sos.
15
conflicts=('sos')
16
options=(!strip !debug)
17
18
source=("$pkgname-$pkgver.tgz::https://registry.npmjs.org/$_npmname/-/${_npmname#*/}-$pkgver.tgz")
19
noextract=("$pkgname-$pkgver.tgz")
20
sha256sums=('fcc4d7f7e107d01daaea4a84ed6b73fbaeb9c9e5a00bf83428d939f8e94eb38f')
21
22
package() {
23
# The only install scripts in the tree are no-ops on Linux: the CLI's own
24
# postinstall requires a postinstall.js that is not in the tarball, and
25
# @signageos/file's has only a win32 variant. npm 12 blocks both anyway.
26
npm install -g \
27
--cache "$srcdir/npm-cache" \
28
--prefix "$pkgdir/usr" \
29
--ignore-scripts \
30
--no-audit --no-fund \
31
"$srcdir/$pkgname-$pkgver.tgz"
32
33
# npm leaves group-writable directories behind.
34
find "$pkgdir/usr" -type d -exec chmod 755 {} +
35
36
# tar-stream (via archiver) depends on bare-fs, which drags in bare-path and
37
# bare-url. Node never loads them: tar-stream maps them only under the `bare`
38
# import condition, and their bindings use require.addon(), which exists only
39
# in the Bare runtime. Their Linux and Android prebuilds would otherwise be
40
# the only ELF files in an arch=any package.
41
rm -r "$pkgdir"/usr/lib/node_modules/$_npmname/node_modules/bare-*/prebuilds
42
43
# The generator replaces a placeholder it matches with four leading spaces,
44
# but the shipped template indents it with tabs, so the per-subcommand case
45
# arms are never inserted and `sos applet <TAB>` offers top-level commands.
46
# Fix the installed template, which also repairs `sos autocomplete install`.
47
local _tpl="$pkgdir/usr/lib/node_modules/$_npmname/dist/Command/Autocomplete/Install/sos-completion.sh"
48
grep -q $'^\t\t# COMMAND_SCHEMA_CASES' "$_tpl"
49
sed -i $'s/^\t\t# COMMAND_SCHEMA_CASES/ # COMMAND_SCHEMA_CASES/' "$_tpl"
50
51
# The completion script is generated from the command tree at runtime and
52
# written to $HOME/.sos-completion.sh (plus a source line appended to the
53
# shell rc), so run the installed CLI against a throwaway HOME and keep only
54
# the script. It uses bash `complete`, so there is no native zsh variant.
55
local _home="$srcdir/home"
56
rm -rf "$_home"
57
mkdir -p "$_home"
58
HOME="$_home" SHELL=/bin/bash "$pkgdir/usr/bin/$_cmd" autocomplete install >/dev/null
59
install -Dm644 "$_home/.sos-completion.sh" \
60
"$pkgdir/usr/share/bash-completion/completions/$_cmd"
61
}
62
63
# vim:set ts=2 sw=2 et:
64
Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-09-24 09:42:26 | Low | 1 |