xcode.plugin.zsh 452 B

123456789101112131415161718
  1. #xc function courtesy of http://gist.github.com/subdigital/5420709
  2. function xc {
  3. xcode_proj=`find . -name "*.xc*" -d 1 | sort -r | head -1`
  4. if [[ `echo -n $xcode_proj | wc -m` == 0 ]]
  5. then
  6. echo "No xcworkspace/xcodeproj file found in the current directory."
  7. else
  8. echo "Found $xcode_proj"
  9. open "$xcode_proj"
  10. fi
  11. }
  12. function xcsel {
  13. sudo xcode-select --switch "$*"
  14. }
  15. alias xcb='xcodebuild'
  16. alias xcp='xcode-select --print-path'