Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How does Xcode know who the project was "created by"?

Tags:

Whenever a new file is added to the project, Xcode adds the following lines of comments on top.

//  Created by {my name here} on 8/4/11. //  Copyright 2011 __{my company name here}__. All rights reserved. 

How does it know what my name is? Does it assume that if my account name belongs to "Mike", "Mike" is the name of the developer writing this code?

Does it then look at Address Book trying to find out what company "Mike" works at? It would make sense, however company listed as part of my address book is not what shows up in the Xcode file.

Can one set the following up in some place where Xcode will read it from?

  • Name
  • Company name
  • some other text describing something important
like image 484
James Raitsev Avatar asked Aug 05 '11 00:08

James Raitsev


People also ask

What does M mean Xcode?

Tags such as "M" or "A" next to files in Xcode indicates that your project in under SVN/GIT repository. "M" indicates content of file Modified whereas "A" for file Added.

What does R mean in Xcode?

M = Locally modified U = Updated in repository A = Locally added D = Locally deleted I = Ignored R = Replaced in the repository – = The contents of the folder have mixed status; display the contents to see individual status ? = Not under source control.

What is .a file Xcode?

a file. You program using the interfaces defined in the . h files, and then configure xcode to link the library in when building your project. To actually use it in your project, add all of your downloaded files to xcode as you normally would, but there is an additional step with the library.

How do I use .a files in Xcode?

After you build your library, you should copy the . a file and the public . h file into a new folder, and add the library to your Xcode project from that folder. Also, in the project build settings, set the Header Search Paths and Library Search Paths setting to that same folder.


1 Answers

In Address Book select yourself (or add yourself if you aren't there) and then go to Card -> Make This My Card in menu bar. The name, last name and company name from that card will be used to populate info in file headers when creating files from Xcode templates.

Alternatively, you could set it using defaults via Terminal.app like this:

defaults write com.apple.Xcode PBXCustomTemplateMacroDefinitions '{ORGANIZATIONNAME="ACME Inc.";}' 
like image 136
Filip Radelic Avatar answered Sep 21 '22 09:09

Filip Radelic