Closed mortenfyhn closed 3 years ago
Thanks @mortenfyhn . Can you confirm the change works with both bash and sh?
Glad you like the edit button. FYI next week the devguide should merge into the user guide. At that point the edit link will do same thing, but is at end of the page - see the test tree here: https://docs.px4.io/v1.devmerge/en/dev_setup/getting_started.html
Sure, I can confirm that this script:
AUTOCNF="yes"
if [ $AUTOCNF == yes ]
then
echo "yes"
fi
runs fine with bash script.sh
but fails with sh script.sh
, error script.sh: 2: [: yes: unexpected operator
While this script:
AUTOCNF="yes"
if [ $AUTOCNF = yes ]
then
echo "yes"
fi
runs properly with both bash and sh.
Thanks very much @mortenfyhn - merged. FYI I hope to merge devguide into user guide in next couple of days. This has been manually copied across.
Just noticed this when reading. Using
==
works with bash, but not with sh.By the way, the "edit page" button leading to automatically creating a fork and letting me suggest changes is very sleek!