You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On my machines (Linux Mint 20.1 and current Kali Linux), patch.sh doesn't work out of the box:
./patch.sh
ramdisk.img: 1 file pushed. 103.9 MB/s (1346686 bytes in 0.012s)
./patch.sh: 5: [[: not found
./patch.sh: 6: [[: not found
busybox: 1 file pushed. 277.2 MB/s (2074240 bytes in 0.007s)
process.sh: 1 file pushed. 7.7 MB/s (11525 bytes in 0.001s)
***** Grab magisk.zip or magisk.apk first ! *****
adb: error: failed to stat remote object '/data/local/tmp/ramdisk.img': No such file or directory
Due to #!/bin/sh in the first line, the script is executed in sh, even while running it from bash. However, at least on my machine sh doesn't know [[. Only bash (and probably some other shells) knows it.
If I run the script using bash ./patch.sh it works fine.
If I simply change the first line to #!/bin/bash it works fine too. I suggest to change it (as long there is no reason to not change it).
The text was updated successfully, but these errors were encountered:
jc97
changed the title
Issue Running patch.sh - bash instead of sh
Issue Running patch.sh - [[ not found - bash instead of sh
Jul 29, 2021
On my machines (Linux Mint 20.1 and current Kali Linux),
patch.sh
doesn't work out of the box:Due to
#!/bin/sh
in the first line, the script is executed in sh, even while running it from bash. However, at least on my machine sh doesn't know[[
. Only bash (and probably some other shells) knows it.If I run the script using
bash ./patch.sh
it works fine.If I simply change the first line to
#!/bin/bash
it works fine too. I suggest to change it (as long there is no reason to not change it).The text was updated successfully, but these errors were encountered: