RE: Project templates
RE: Project templates
- Subject: RE: Project templates
- From: "Karan, Cem (Civ, ARL/CISD)" <email@hidden>
- Date: Thu, 26 Jun 2008 09:37:09 -0400
- Thread-topic: Project templates
OK, I'm going to reply to multiple messages at once, just to keep the
noise down.
Chris, Andy, thank you for information; that was what I was looking for.
Scott, I understand the need for bug reports, and I agree with you; I
wasn't suggesting this discussion in place of a well-written bug report,
I wanted to discuss what everyone on the list was interested in, so that
I can write up a final feature-list, etc. that goes into the bug report.
I'm hoping to cut down on the amount of work you guys need to do, and
the amount of complaining on the list later on if something is missing
;-).
I like Philip's idea of an sdef file as that allows the use of many
different languages. The only question then is what elements are
necessary in the file. I propose that we have the ability to get the
following:
Metadata - Note that although I have the elements below listed as
separate objects, they should probably be keys in a dictionary. E.g.
{'Version':1,
'ReleaseNotesURI':'file:///Developer/localized/release/notes.html',
etc.}
VERSION - A monotonically incrementing integer value that indicates the
template dictionary version. I think this will address concerns about
future proofing; as end-users, we can fix our scripts to check this
version number, and if its changed, we'll have to go through and figure
out what the changes are.
RELEASENOTESURI - This is a URI to some release notes documentation.
The reason I'm suggesting a URI rather than embedding the documentation
directly is because of localization; I haven't seen anything in the sdef
man pages that suggests they support localization directly. Putting in
an HTML file that is localized to whatever language Xcode supports
should be fairly easy.
Elements
DATE - A dictionary that contains the various parts of a date. E.g.
{'NSDateFormatterShortStyleDate':'6/26/08',
'NSDateFormatterShortStyleTime':'9:14am','NSDateFormatterMediumStyleDate
':'Jun 26, 2008', 'WeekDay':'Thursday', 'FullYear':'2008',
'ShortYear':'08', 'FullMonth':'June', 'ShortMonth':'Jun', 'Hour':'08',
etc.}. We can grab these elements and make up our own date string, or
use the default date string.
FILE - A dictionary that contains various elements related to the file
the user wants to generate. E.g.
{'FullPath':'/Users/foo/Documents/Projects/MyNiftyProject/bar.c',
'BaseName':'foo', 'Extension':'c',
'UUID':'748B2FCA-99C4-4D2F-84C4-12B7735EFCAB'}. Maybe file attributes
(like what ls -@ kicks out) too?
PRODUCT - A dictionary that contains various elements related to the
product being made. E.g. {'ProductName':'Foo', etc.}
TARGET - A dictionary that contains various elements related to the
target being made.
TEMPLATE - A dictionary containing 3 elements; the full text of the
template file, the start marker, and the end marker. E.g.
{'Text':'...text...', 'StartMarker':'<<', 'EndMarker':'>>'}. This
simplifies parsing as the start and end markers may need to be changed
depending on the encoding of the original files (basically, I don't know
if all the template files are in unicode yet or not; the '<<' and '>>'
markers in the template files may map to something printable in another
encoding, and may need to be replaced)
USER - A dictionary that contains various elements related to the user
that generated the file. E.g. {'FullUserName':'Foo B. Bar',
'FirstName':'Foo', 'MiddleName':'B.', 'LastName':'Bar',
'LoginName':'fbar', 'UID':12345, etc.}
I know there is more stuff that can be added, but this is just the
start. Any thoughts from anyone out there? Should all key/values be
strings (makes parsing easy), or should they be a mix of strings,
integers, etc.?
Thanks,
Cem Karan
_______________________________________________
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