melt-mdeditor-git
Triggered rules
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 and npx executions are part of building the project from source and use declared dependencies; the use of a mirror in China is a regional optimization, not malicious code execution.
2 higher static findings superseded - not the current verdict (shown for transparency)
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:75
NODE_ENV=development npm add -D rollup
remote_code_tool
`npx`/`bunx`/`pnpm dlx`/`deno run <url>` downloads AND runs a remote package at build time — the moral equivalent of piping a download into a shell. Severity downgraded: Node.js consumer context.
-
PKGBUILD:80
NODE_ENV=production npx vue-tsc --noEmit -
PKGBUILD:81
NODE_ENV=production npx vite build
PKGBUILD
3 offending line(s) highlighted# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
_pkgname=melt
pkgname="${_pkgname}-mdeditor-git"
_appname=Melt
pkgver=2.12.1.r0.gec6da7b
_electronversion=27
_nodeversion=20
pkgrel=1
pkgdesc="A Markdown Editor.Based on the GitHub Flavored Markdown Spec.(Use system-wide electron)"
arch=('x86_64')
url="https://github.com/qazsato/melt"
license=('MIT')
conflicts=("${pkgname%-git}")
provides=("${pkgname%-git}")
depends=(
"electron${_electronversion}"
)
makedepends=(
'gendesk'
'git'
'npm'
'nvm'
'curl'
'libicns'
)
source=(
"${pkgname%-git}.git::git+${url}.git"
"${pkgname%-git}.sh"
)
sha256sums=('SKIP'
'291f50480f5a61bc9c68db7d44cd0412071128706baa868a9cb854f8779a1980')
pkgver() {
cd "${srcdir}/${pkgname%-git}.git"
set -o pipefail
git describe --long --tags --abbrev=7 | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/v//g' ||
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short=7 HEAD)"
}
_ensure_local_nvm() {
local NVM_DIR="${srcdir}/.nvm"
source /usr/share/nvm/init-nvm.sh || [[ $? != 1 ]]
nvm install "${_nodeversion}"
nvm use "${_nodeversion}"
}
prepare() {
sed -i -e "
s/@electronversion@/${_electronversion}/g
s/@appname@/${pkgname%-git}/g
s/@runname@/app.asar/g
s/@cfgdirname@/${_pkgname}/g
s/@options@/env ELECTRON_OZONE_PLATFORM_HINT=auto/g
" "${srcdir}/${pkgname%-git}.sh"
_ensure_local_nvm
gendesk -q -f -n --pkgdesc="${pkgdesc}" --categories="Utility" --pkgname="${pkgname%-git}" --name="${_pkgname}" --exec="${pkgname%-git} %U"
cd "${srcdir}/${pkgname%-git}.git"
export ELECTRON_SKIP_BINARY_DOWNLOAD=1
export SYSTEM_ELECTRON_VERSION="$(electron${_electronversion} -v | sed 's/v//g')"
HOME="${srcdir}/.electron-gyp"
{
echo -e '\n'
#echo 'build_from_source=true'
echo "cache=${srcdir}/.npm_cache"
} >> .npmrc
if [[ "$(curl -s ipinfo.io/country)" == *"CN"* ]]; then
{
echo 'registry=https://registry.npmmirror.com'
echo 'electron_mirror=https://registry.npmmirror.com/-/binary/electron/'
echo 'electron_builder_binaries_mirror=https://registry.npmmirror.com/-/binary/electron-builder-binaries/'
} >> .npmrc
find ./ -type f -name "package-lock.json" -exec sed -i "s/registry.npmjs.org/registry.npmmirror.com/g" {} +
fi
icns2png -x public/icon.icns -o public
sed -i "s/\${version}//g" electron-builder.json5
sed -i "s/\"electron\": \"[^\"]*\"/\"electron\": \"${SYSTEM_ELECTRON_VERSION}\"/g" package.json
NODE_ENV=development npm install --force
NODE_ENV=development npm add -D rollup
}
build() {
cd "${srcdir}/${pkgname%-git}.git"
local electronDist="/usr/lib/electron${_electronversion}"
NODE_ENV=production npx vue-tsc --noEmit
NODE_ENV=production npx vite build
NODE_ENV=production npm exec -c "electron-builder --linux dir -c.electronDist=${electronDist} --config electron-builder.json5"
}
package() {
install -Dm755 "${srcdir}/${pkgname%-git}.sh" "${pkgdir}/usr/bin/${pkgname%-git}"
install -Dm644 "${srcdir}/${pkgname%-git}.git/release/linux-unpacked/resources/app.asar" -t "${pkgdir}/usr/lib/${pkgname%-git}"
install -Dm644 "${srcdir}/${pkgname%-git}.git/public/icon_512x512x32.png" "${pkgdir}/usr/share/pixmaps/${pkgname%-git}.png"
install -Dm644 "${srcdir}/${pkgname%-git}.desktop" -t "${pkgdir}/usr/share/applications"
}
Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-08-03 00:08:14 | LOW | 3 |
| 2026-08-02 00:16:08 | LOW | 3 |
| 2026-08-01 00:11:18 | LOW | 3 |
| 2026-07-31 00:14:10 | LOW | 3 |
| 2026-07-30 00:17:23 | LOW | 3 |
| 2026-07-29 00:25:53 | LOW | 3 |
| 2026-07-28 00:07:28 | LOW | 3 |
| 2026-07-27 00:24:32 | LOW | 3 |
| 2026-07-26 00:07:32 | LOW | 3 |
| 2026-07-25 00:13:44 | LOW | 3 |
| 2026-07-24 00:02:28 | LOW | 3 |
| 2026-07-23 00:14:47 | LOW | 3 |
| 2026-07-22 00:29:32 | LOW | 3 |
| 2026-07-21 00:24:15 | LOW | 3 |
| 2026-07-20 00:19:49 | LOW | 3 |
| 2026-07-19 00:17:08 | LOW | 3 |
| 2026-07-18 00:14:48 | LOW | 3 |
| 2026-07-17 00:06:16 | LOW | 3 |
| 2026-07-16 00:05:41 | LOW | 3 |
| 2026-07-15 00:09:25 | LOW | 3 |