1
0

plug-bin 321 B

123456789101112131415
  1. #!/usr/bin/env bash
  2. snapctl is-connected bin
  3. if [ $? -eq 0 ]; then
  4. readarray -d '' PATHS < <(find $SNAP -maxdepth 2 -type d -name bin -path "$SNAP/shared-bin*" -print0)
  5. if [ "${#PATHS[@]}" -ne 0 ]; then
  6. for TPATH in "${PATHS[@]}"; do
  7. PATH="${PATH}:${TPATH}"
  8. done
  9. fi
  10. fi
  11. eval $@