mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-04-14 10:07:39 +08:00
px4-alias.sh_in:Remove source and add R=${pwd}
px4-alias.sh_in:Remove sh alias
This commit is contained in:
parent
b846ddffd8
commit
d4ae3985b3
@ -1,6 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
# File is auto-generated by cmake compilation, do not edit.
|
||||
R="`pwd`/"
|
||||
|
||||
# Map the NuttX-style variable definition 'set <var> <value>' to something that
|
||||
# bash and alternatives understand
|
||||
@ -9,37 +10,6 @@ _set() {
|
||||
eval $1=\"$2\"
|
||||
}
|
||||
alias set=_set
|
||||
# alternative method with an alias:
|
||||
# alias set='f(){ set -- "$1=$2"; eval "$1"; unset -f f; }; eval f'
|
||||
|
||||
# Execute another shell script.
|
||||
# $1: Path to the script, (optionally starts with /, to match with the NuttX
|
||||
# scripts)
|
||||
sh() {
|
||||
script="$1"
|
||||
case "$script" in
|
||||
"/"*)
|
||||
script="$script"
|
||||
;;
|
||||
*)
|
||||
script="/$script"
|
||||
;;
|
||||
esac
|
||||
. "$(pwd)$script"
|
||||
}
|
||||
|
||||
source() {
|
||||
script="$1"
|
||||
case "$script" in
|
||||
"/"*)
|
||||
script="$script"
|
||||
;;
|
||||
*)
|
||||
script="/$script"
|
||||
;;
|
||||
esac
|
||||
. "$(pwd)$script"
|
||||
}
|
||||
|
||||
# Don't stop on errors.
|
||||
#set -e
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user