database-kit-git
maintainer zxp19821005
· 0 votes
· scanned 2026-08-03 00:08:14.047287
LOW
View on AUR ↗
Why flagged
The npm install runs in the build environment with dependencies from the project's own source; the added dev dependency is part of a standard build process using electron-forge and does not introduce untrusted remote code execution.
Triggered rules
LOW
AI review downgraded a static finding
llm_review
The static rules flagged this MEDIUM, but an AI model (qwen/qwen3-235b-a22b-07-25) reviewed the full PKGBUILD and judged it LOW (confidence 95%): The npm install runs in the build environment with dependencies from the project's own source; the added dev dependency is part of a standard build process using electron-forge and does not introduce untrusted remote code execution.
1 higher static finding superseded - not the current verdict (shown for transparency)
MEDIUM
npm/yarn/pnpm install of an undeclared external package
npm_install_external
Runs `npm/yarn/pnpm install <package>` for a package not in source=(), pulling unpinned, unreviewed code at build time. Severity downgraded: the package declares/looks like a Node.js consumer, where build-time installs are expected.
-
PKGBUILD:78
NODE_ENV=development npm add -D @electron-forge/plugin-local-electron --legacy-peer-deps
PKGBUILD
1 offending line(s) highlighted
1
# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
2
pkgname=database-kit-git
3
_pkgname='Database Kit'
4
pkgver=0.0.2.r2.g1411897
5
_electronversion=31
6
_nodeversion=20
7
pkgrel=1
8
pkgdesc="A database management toolset, providing an intuitive graphical interface to manage database connections, execute commands, and edit configuration files.(Use system-wide electron)"
9
arch=('any')
10
url="https://github.com/zhuyongqi-master/database-kit"
11
license=('LicenseRef-unknown')
12
provides=("${pkgname%-git}=${pkgver%.r*}")
13
conflicts=("${pkgname%-git}")
14
depends=(
15
"electron${_electronversion}"
16
)
17
makedepends=(
18
'npm'
19
'nvm'
20
'git'
21
'curl'
22
'gendesk'
23
)
24
source=(
25
"${pkgname%-git}.git::git+${url}.git"
26
"${pkgname%-git}.sh"
27
)
28
sha256sums=('SKIP'
29
'291f50480f5a61bc9c68db7d44cd0412071128706baa868a9cb854f8779a1980')
30
pkgver() {
31
cd "${srcdir}/${pkgname%-git}.git"
32
set -o pipefail
33
git describe --long --tags --abbrev=7 | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/v//g' ||
34
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short=7 HEAD)"
35
}
36
_ensure_local_nvm() {
37
local NVM_DIR="${srcdir}/.nvm"
38
source /usr/share/nvm/init-nvm.sh || [[ $? != 1 ]]
39
nvm install "${_nodeversion}"
40
nvm use "${_nodeversion}"
41
}
42
prepare() {
43
cd "${srcdir}/${pkgname%-git}.git"
44
sed -i -e "
45
s/@electronversion@/${_electronversion}/g
46
s/@appname@/${pkgname%-git}/g
47
s/@runname@/app.asar/g
48
s/@cfgdirname@/${pkgname%-git}/g
49
s/@options@/env ELECTRON_OZONE_PLATFORM_HINT=auto/g
50
" "${srcdir}/${pkgname%-git}.sh"
51
_ensure_local_nvm
52
gendesk -q -f -n \
53
--pkgname="${pkgname%-git}" \
54
--pkgdesc="${pkgdesc}" \
55
--categories="Development" \
56
--name="${_pkgname}" \
57
--exec="${pkgname%-git} %U"
58
export SYSTEM_ELECTRON_VERSION="$(electron${_electronversion} -v | sed 's/v//g')"
59
HOME="${srcdir}/.electron-gyp"
60
{
61
echo -e '\n'
62
#echo 'build_from_source=true'
63
echo "cache=${srcdir}/.npm_cache"
64
echo "maxsockets=10"
65
} >> .npmrc
66
if [[ "$(curl -s ipinfo.io/country)" == *"CN"* ]]; then
67
{
68
echo 'registry=https://registry.npmmirror.com'
69
echo 'electron_mirror=https://registry.npmmirror.com/-/binary/electron/'
70
echo 'electron_builder_binaries_mirror=https://registry.npmmirror.com/-/binary/electron-builder-binaries/'
71
} >> .npmrc
72
find ./ -type f -name "package-lock.json" -exec sed -i "s/registry.npmjs.org/registry.npmmirror.com/g" {} +
73
fi
74
sed -i '/"include": \["src"\],/a\ "exclude": ["src/**/*.d.ts"],' tsconfig.json
75
sed -i 's#"include": \["src"\],#"include": ["src/**/*.{ts,tsx}"],#g' tsconfig.json
76
sed -i "s/\"electron\": \"[^\"]*\"/\"electron\": \"${SYSTEM_ELECTRON_VERSION}\"/g" package.json
77
NODE_ENV=development npm install --legacy-peer-deps
78
NODE_ENV=development npm add -D @electron-forge/plugin-local-electron --legacy-peer-deps
79
}
80
build() {
81
cd "${srcdir}/${pkgname%-git}.git"
82
export ELECTRON_SKIP_BINARY_DOWNLOAD=1
83
local electronDist="/usr/lib/electron${_electronversion}"
84
sed -i '/makers: \[/i\
85
plugins: [\
86
{\
87
name: "@electron-forge/plugin-local-electron",\
88
config: {\
89
electronPath: "'"${electronDist}"'",\
90
},\
91
},\
92
],' forge.config.*
93
NODE_ENV=production npm run build
94
NODE_ENV=production npm run package
95
}
96
package() {
97
install -Dm755 "${srcdir}/${pkgname%-git}.sh" "${pkgdir}/usr/bin/${pkgname%-git}"
98
install -Dm644 "${srcdir}/${pkgname%-git}.git/out/${pkgname%-git}-linux-"*/resources/app.asar -t "${pkgdir}/usr/lib/${pkgname%-git}"
99
#install -Dm644 "${srcdir}/${pkgname%-git}.git/assets/icon.png" "${pkgdir}/usr/share/pixmaps/${pkgname%-git}.png"
100
install -Dm644 "${srcdir}/${pkgname%-git}.git/${pkgname%-git}.desktop" -t "${pkgdir}/usr/share/applications"
101
install -Dm644 "${srcdir}/${pkgname%-git}.git/README.md" -t "${pkgdir}/usr/share/licenses/${pkgname}"
102
}
Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-08-03 00:08:14 | LOW | 2 |
| 2026-08-02 00:16:08 | LOW | 2 |
| 2026-08-01 00:11:18 | LOW | 2 |
| 2026-07-31 00:14:10 | LOW | 2 |
| 2026-07-30 00:17:23 | LOW | 2 |
| 2026-07-29 00:25:53 | LOW | 2 |
| 2026-07-28 00:07:28 | LOW | 2 |
| 2026-07-27 00:24:32 | LOW | 2 |
| 2026-07-26 00:07:32 | LOW | 2 |
| 2026-07-25 00:13:44 | LOW | 2 |
| 2026-07-24 00:02:28 | LOW | 2 |
| 2026-07-23 00:14:47 | LOW | 2 |
| 2026-07-22 00:29:32 | LOW | 2 |
| 2026-07-21 00:24:15 | LOW | 2 |
| 2026-07-20 00:19:49 | LOW | 2 |
| 2026-07-19 00:17:08 | LOW | 2 |
| 2026-07-18 00:14:48 | LOW | 2 |
| 2026-07-17 00:06:16 | LOW | 2 |
| 2026-07-16 00:05:41 | LOW | 2 |
| 2026-07-15 00:09:25 | LOW | 2 |