Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Line delimiters, file properties

Through File Properties, RTC supports setting line delimiter behaviour for a file or all files with a certain suffix. For example, a file or all files with a certain suffix can be set to have line delimiter "Platform".

We are seeing some issues with files getting delivered with incorrect line delimiter property. I have a few questions as a result.

1. If userA configures the delimiter property for files with a given suffix on an RTC project in his workspace, is this change (delimiter property per suffix) applied to the associated RTC component in the repository? i.e. does it apply to files with same suffix subsequently added by other users?

2. If the user makes that change, are all affected files in his workspace for that project changed as necessary and deliverable, or does it only apply to new files created subsequently?

3. If userA updates jazz file properties preferences in his RTC, is there a way to export and share those preferences with other users?

4. Is there a way to update delimiter property per file suffix globally in a repository, e.g. across multi component, multi stream repository?

0 votes



One answer

Permanent link
1) I assume when you say "configure" you mean "configure his preference".
- This is strictly an eclipse preference. It only applies to his
'eclipse workspace'. So no, it does not get applied in the repository and
adopted by other users.

2) The preference change is only for new files subsequently created. To
affect currently existing files, those files need to be loaded on disk
first. Then from the Package Explorer, you can choose Team>Change File
Properties on individual resources or on folders.
- Warning, if you do this on (multiple) folders with lots of children,
you can easily run into scanning and modifying thousands of files (and the
UI becomes clunky and slow). I have a work item against me to optimize
this.
- You could also try using the command line run a script to do this. If I
recall correctly: scm property set jazz.linedelimiter

- Doing this will make an outgoing change. Deliver this change so that
other people can accept it and have the same line delimiters as you.
- So, if you do this, I recommend picking manageable subfolders to work
with. This also means you make multiple change sets (instead of 1 giant
one), which will be easier to roll-back if something goes disastrously
wrong (to ALL your files)

3. This follows from point 1). You could export your eclipse preferences
and import them into all your neighbor's eclipses, but that is outside of
RTC. There is no 'team preferences' that is shared for source control. It
is something we have discussed in the past. This kind of feature needs the
proper planning for time/implementation details vs other features.

4. No, the files need to be loaded on disk first to apply changes, and
then upload them into the repository. This is because just 'declaring' a
file has a particular line delimiter isn't enough, the file needs to be
modified to make it hold true.
- Following from comment 2, if you're planning to invest your time to make
this all 'right', then you might want to consider trying to write a
command line script for it instead of doing it from the UI.

Alternatively, you can incrementally fix them as you edit the files. Have
your team set their preferences (for new files) and have them be aware of
files types that you want have control over the line delimiter. When they
edit a file and notice it is wrong, then they can fix it. If a file is
'wrong' but nobody ever edits it (and the build passes, and everything
that matters still works) then maybe they're ok to just leave 'wrong'.
(weighing this option opposed to spending a day getting a command line
script correct... and then having it load and unload your entire
repository to make these changes).

- but I do understand the 'clean' feeling you get when you know that every
resource in the repository is 'perfect and the way they should be and will
never go wrong ever after'.



On Thu, 12 Nov 2009 07:23:03 -0500, echalmer
<ewan> wrote:

Through File Properties, RTC supports setting line delimiter behaviour
for a file or all files with a certain suffix. For example, a file or
all files with a certain suffix can be set to have line delimiter
"Platform".

We are seeing some issues with files getting delivered with incorrect
line delimiter property. I have a few questions as a result.

1. If userA configures the delimiter property for files with a given
suffix on an RTC project in his workspace, is this change (delimiter
property per suffix) applied to the associated RTC component in the
repository? i.e. does it apply to files with same suffix subsequently
added by other users?

2. If the user makes that change, are all affected files in his
workspace for that project changed as necessary and deliverable, or
does it only apply to new files created subsequently?

3. If userA updates jazz file properties preferences in his RTC, is
there a way to export and share those preferences with other users?

4. Is there a way to update delimiter property per file suffix
globally in a repository, e.g. across multi component, multi stream
repository?



--

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details

Question asked: Nov 12 '09, 7:11 a.m.

Question was seen: 5,805 times

Last updated: Nov 12 '09, 7:11 a.m.

Confirmation Cancel Confirm