Fix setup.sh on MacOS due to gnu vs bsd sed (#1635)

pull/1641/head
Disconnect3d 3 years ago committed by GitHub
parent 35769a88ab
commit cf63cc326e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -169,7 +169,13 @@ ${PYTHON} -m pip install ${INSTALLFLAGS} -Ur requirements.txt
# Comment old configs out
if grep -q '^[^#]*source.*pwndbg/gdbinit.py' ~/.gdbinit; then
sed -i '/^[^#]*source.*pwndbg\/gdbinit.py/ s/^/# /' ~/.gdbinit
if ! osx; then
sed -i '/^[^#]*source.*pwndbg\/gdbinit.py/ s/^/# /' ~/.gdbinit
else
# In BSD sed we need to pass ' ' to indicate that no backup file should be created
sed -i ' ' '/^[^#]*source.*pwndbg\/gdbinit.py/ s/^/# /' ~/.gdbinit
fi
fi
# Load Pwndbg into GDB on every launch.

Loading…
Cancel
Save