forked from jverkoey/nimbus
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPbxproj.html
More file actions
161 lines (135 loc) · 9.99 KB
/
Pbxproj.html
File metadata and controls
161 lines (135 loc) · 9.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<!doctype html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><title>Python: module Pbxproj</title>
</head><body bgcolor="#f0f0f8">
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
<tr bgcolor="#7799ee">
<td valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong>Pbxproj</strong></big></big></font></td
><td align=right valign=bottom
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/Users/featherless/workbench/ios/three20/src/scripts/Pbxproj.py">/Users/featherless/workbench/ios/three20/src/scripts/Pbxproj.py</a></font></td></tr></table>
<p><tt><a href="#Pbxproj">Pbxproj</a>.py<br>
<br>
Working with the pbxproj file format is a pain in the ass.<br>
<br>
This <a href="__builtin__.html#object">object</a> provides a couple basic features for parsing pbxproj files:<br>
<br>
* Getting a dependency list<br>
* Adding one pbxproj to another pbxproj as a dependency<br>
<br>
Version 1.0.<br>
<br>
History:<br>
1.0 - October 20, 2010: Initial hacked-together version finished. It is alive!<br>
<br>
Created by Jeff Verkoeyen on 2010-10-18.<br>
Copyright 2009-2010 Facebook<br>
<br>
Licensed under the Apache License, Version 2.0 (the "License");<br>
you may not use this file except in compliance with the License.<br>
You may obtain a copy of the License at<br>
<br>
<a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a><br>
<br>
Unless required by applicable law or agreed to in writing, software<br>
distributed under the License is distributed on an "AS IS" BASIS,<br>
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.<br>
See the License for the specific language governing permissions and<br>
limitations under the License.</tt></p>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#aa55cc">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="Paths.html">Paths</a><br>
<a href="hashlib.html">hashlib</a><br>
</td><td width="25%" valign=top><a href="logging.html">logging</a><br>
<a href="os.html">os</a><br>
</td><td width="25%" valign=top><a href="re.html">re</a><br>
<a href="sys.html">sys</a><br>
</td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ee77aa">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
<td width="100%"><dl>
<dt><font face="helvetica, arial"><a href="__builtin__.html#object">__builtin__.object</a>
</font></dt><dd>
<dl>
<dt><font face="helvetica, arial"><a href="Pbxproj.html#Pbxproj">Pbxproj</a>
</font></dt></dl>
</dd>
</dl>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ffc8d8">
<td colspan=3 valign=bottom> <br>
<font color="#000000" face="helvetica, arial"><a name="Pbxproj">class <strong>Pbxproj</strong></a>(<a href="__builtin__.html#object">__builtin__.object</a>)</font></td></tr>
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
<td width="100%">Methods defined here:<br>
<dl><dt><a name="Pbxproj-__init__"><strong>__init__</strong></a>(self, name)</dt><dd><tt># Valid names<br>
# Three20<br>
# Three20:Three20-Xcode3.2.5<br>
# /path/to/project.xcodeproj/project.pbxproj</tt></dd></dl>
<dl><dt><a name="Pbxproj-__str__"><strong>__str__</strong></a>(self)</dt></dl>
<dl><dt><a name="Pbxproj-add_build_setting"><strong>add_build_setting</strong></a>(self, configuration, setting_name, value)</dt></dl>
<dl><dt><a name="Pbxproj-add_buildfile"><strong>add_buildfile</strong></a>(self, name, file_ref_hash, default_guid)</dt><dd><tt># Add a line to the PBXBuildFile section.<br>
#<br>
# <default_guid> /* <name> in Frameworks */ = {isa = PBXBuildFile; fileRef = <file_ref_hash> /* <name> */; };<br>
#<br>
# Returns: <default_guid> if a line was added.<br>
# Otherwise, the existing guid is returned.</tt></dd></dl>
<dl><dt><a name="Pbxproj-add_dependency"><strong>add_dependency</strong></a>(self, dep)</dt></dl>
<dl><dt><a name="Pbxproj-add_file_to_frameworks"><strong>add_file_to_frameworks</strong></a>(self, name, guid)</dt><dd><tt># Add a file to the Frameworks PBXGroup.<br>
#<br>
# <guid> /* <name> */,</tt></dd></dl>
<dl><dt><a name="Pbxproj-add_file_to_frameworks_phase"><strong>add_file_to_frameworks_phase</strong></a>(self, name, guid)</dt></dl>
<dl><dt><a name="Pbxproj-add_filereference"><strong>add_filereference</strong></a>(self, name, file_type, default_guid, rel_path, source_tree)</dt><dd><tt># Add a line to the PBXFileReference section.<br>
#<br>
# <default_guid> /* <name> */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.<file_type>"; name = <name>; path = <rel_path>; sourceTree = <source_tree>; };<br>
#<br>
# Returns: <default_guid> if a line was added.<br>
# Otherwise, the existing guid is returned.</tt></dd></dl>
<dl><dt><a name="Pbxproj-add_framework"><strong>add_framework</strong></a>(self, framework)</dt></dl>
<dl><dt><a name="Pbxproj-add_header_search_path"><strong>add_header_search_path</strong></a>(self, configuration)</dt></dl>
<dl><dt><a name="Pbxproj-dependencies"><strong>dependencies</strong></a>(self)</dt><dd><tt># Get and cache the dependencies for this project.</tt></dd></dl>
<dl><dt><a name="Pbxproj-get_hash_base"><strong>get_hash_base</strong></a>(self, uniquename)</dt></dl>
<dl><dt><a name="Pbxproj-get_project_data"><strong>get_project_data</strong></a>(self)</dt><dd><tt># Load the project data from disk.</tt></dd></dl>
<dl><dt><a name="Pbxproj-guid"><strong>guid</strong></a>(self)</dt></dl>
<dl><dt><a name="Pbxproj-path"><strong>path</strong></a>(self)</dt></dl>
<dl><dt><a name="Pbxproj-set_project_data"><strong>set_project_data</strong></a>(self, project_data)</dt><dd><tt># Write the project data to disk.</tt></dd></dl>
<dl><dt><a name="Pbxproj-uniqueid"><strong>uniqueid</strong></a>(self)</dt></dl>
<dl><dt><a name="Pbxproj-xcodeprojpath"><strong>xcodeprojpath</strong></a>(self)</dt><dd><tt># A pbxproj file is contained within an xcodeproj file.<br>
# This method simply strips off the project.pbxproj part of the path.</tt></dd></dl>
<hr>
Static methods defined here:<br>
<dl><dt><a name="Pbxproj-get_pbxproj_by_name"><strong>get_pbxproj_by_name</strong></a>(name)</dt></dl>
<hr>
Data descriptors defined here:<br>
<dl><dt><strong>__dict__</strong></dt>
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
</dl>
<dl><dt><strong>__weakref__</strong></dt>
<dd><tt>list of weak references to the object (if defined)</tt></dd>
</dl>
</td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#eeaa77">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Functions</strong></big></font></td></tr>
<tr><td bgcolor="#eeaa77"><tt> </tt></td><td> </td>
<td width="100%"><dl><dt><a name="-commonpath"><strong>commonpath</strong></a>(l1, l2, common<font color="#909090">=[]</font>)</dt></dl>
<dl><dt><a name="-pathsplit"><strong>pathsplit</strong></a>(p, rest<font color="#909090">=[]</font>)</dt><dd><tt># The following relative path methods recyled from:<br>
# <a href="http://code.activestate.com/recipes/208993-compute-relative-path-from-one-directory-to-anothe/">http://code.activestate.com/recipes/208993-compute-relative-path-from-one-directory-to-anothe/</a><br>
# Author: Cimarron Taylor<br>
# Date: July 6, 2003</tt></dd></dl>
<dl><dt><a name="-relpath"><strong>relpath</strong></a>(p1, p2)</dt></dl>
</td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#55aa55">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
<td width="100%"><strong>pbxproj_cache</strong> = {}</td></tr></table>
</body></html>