mirror of
https://github.com/radareorg/radare2.git
synced 2025-02-03 12:12:06 +00:00
Add www-m r2pm pkg
This commit is contained in:
parent
d1455c5aa6
commit
9fec5ae3b2
31
binr/r2pm/d/www-m
Normal file
31
binr/r2pm/d/www-m
Normal file
@ -0,0 +1,31 @@
|
||||
R2PM_BEGIN
|
||||
|
||||
R2PM_GIT "https://github.com/radare/radare2-webui"
|
||||
R2PM_DESC "[r2-www] The Material WebUI of /m"
|
||||
|
||||
R2PM_INSTALL() {
|
||||
cd www/m || exit 1
|
||||
make || exit 1
|
||||
WWWROOT=`r2 -qce' http.root' - 2> /dev/null`
|
||||
if [ -n "${WWWROOT}" ]; then
|
||||
rm -rf "${WWWROOT}/m"/*
|
||||
mkdir -p "${WWWROOT}/m"
|
||||
echo "Installing /m..."
|
||||
tar xzvf dist.tar.gz -C "${WWWROOT}/m"
|
||||
else
|
||||
echo "Cannot find WWWROOT"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
R2PM_UNINSTALL() {
|
||||
WWWROOT=`r2 -qce' http.root' - 2>/dev/null`
|
||||
if [ -n "${WWWROOT}" ]; then
|
||||
rm -rf "{WWWROOT}/m"
|
||||
else
|
||||
echo "Cannot find WWWROOT"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
R2PM_END
|
Loading…
x
Reference in New Issue
Block a user