• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
A script to click the "Files with source-control status" button in Xcode
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

A script to click the "Files with source-control status" button in Xcode


  • Subject: A script to click the "Files with source-control status" button in Xcode
  • From: Alex Zavatone <email@hidden>
  • Date: Tue, 27 Sep 2016 11:40:05 -0500

That little M at the bottom of the Xcode project Navigator that we use to show all files that are modified or not?

The one without a shortcut key?

Assuming that window 1 in Xcode is showing the Project Navigator, this script will check/uncheck the M button that shows whether or not files need to be checked in or not.

Tested in Xcode 7.3.1.

Open your Script Editor and paste into a new AppleScript doc.  Make sure that GUI Scripting is enabled.

You can take this and map a key to open this as an app which will click the button.  Of course, I'd make this a little more robust first.




tell application "System Events"
set myWindow to window 1 of process "Xcode"
click checkbox "Files with source-control status" of text field 1 of group 1 of splitter group 1 of group 1 of myWindow
end tell


Hope this is of use to some of us.

- Alex Zavatone

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Question on passing events to multithreaded OpenGL apps
  • Next by Date: Collection View Storyboard layout wrong in Xcode 8.x
  • Previous by thread: Question on passing events to multithreaded OpenGL apps
  • Next by thread: Collection View Storyboard layout wrong in Xcode 8.x
  • Index(es):
    • Date
    • Thread