Skip to content

Instantly share code, notes, and snippets.

@zenHeart
Created January 23, 2019 15:09
Show Gist options
  • Save zenHeart/e3cf2977b180b67c4932f8d931941487 to your computer and use it in GitHub Desktop.
Save zenHeart/e3cf2977b180b67c4932f8d931941487 to your computer and use it in GitHub Desktop.
获取执行脚本的所在目录
#!/usr/bin/env sh
SCRIPT_DIR=$(cd `dirname $0`;pwd);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment