diff --git a/setup_env.sh b/setup_env.sh index 211417e..fe39a14 100755 --- a/setup_env.sh +++ b/setup_env.sh @@ -60,9 +60,14 @@ migrate_and_link() { local target=$1 local link_name=$2 - if [[ ! -e "$target" && -f "$link_name" && ! -L "$link_name" ]]; then - echo "Migrating existing $link_name -> $target" - cp "$link_name" "$target" + if [[ ! -e "$target" ]]; then + if [[ -f "$link_name" && ! -L "$link_name" ]]; then + echo "Migrating existing $link_name -> $target" + cp "$link_name" "$target" + elif [[ -f "${target}_example" ]]; then + echo "Bootstrapping $target from example (fill in real values)" + cp "${target}_example" "$target" + fi fi create_symlink "$target" "$link_name"