mirror of
https://github.com/denisidoro/navi
synced 2024-11-22 03:23:05 +00:00
15 lines
No EOL
255 B
Bash
Executable file
15 lines
No EOL
255 B
Bash
Executable file
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
export NAVI_HOME="$(cd "$(dirname "$0")/.." && pwd)"
|
|
|
|
script() {
|
|
echo "#!/usr/bin/env bash"
|
|
echo "${NAVI_HOME}/navi" '"$@"'
|
|
}
|
|
|
|
folder="${1:-/usr/local/bin}"
|
|
bin="${folder}/navi"
|
|
|
|
script > "$bin"
|
|
chmod +x "$bin" |