Home » Eclipse Projects » Oomph » ResourceCreation of .options file in Eclipse install Directory
| | |
Re: ResourceCreation of .options file in Eclipse install Directory [message #1710259 is a reply to message #1710205] |
Mon, 05 October 2015 14:55 |
Ed Merks Messages: 33258 Registered: July 2009 |
Senior Member |
|
|
Simon,
No, there's nothing for that yet. Aren't the contents of that folder
signed and therefore shouldn't be modified?
On 05/10/2015 1:03 PM, Simon Laffoy wrote:
> Quote:
>> Hi,
>>
>> have you tried the following?
>>
>> ${installation.location}/.options or
>> ${installation.location|uri}/.options
>>
>> Alex
>
>
> Hi, thanks for the suggestion.
> I hadn't tried those because I hadn't expected them to work, but just
> to be sure I tried them anyway. I believe that your above suggestion
> would work on Windows, however not on Mac (which I am using).
> Apologies, but it is clear to me now that I did a poor job of defining
> the problem in the initial post of the thread. Let me do so now ...
>
> I need the option file to be saved in the same directory as the
> eclipse executable file. In Mac that would be something like
>
> ${installation.location}/Eclipse.app/Contents/MacOS/.options
> Now, I could just use the above and I would have something that works
> on Mac, but then it would not work on Windows.
>
> I am looking for some variable which represents the directory where
> the .exe file is saved and which is platform independent.
>
> Apologies for not having more clearly defined this in the opening post
> of the thread.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
| |
Re: ResourceCreation of .options file in Eclipse install Directory [message #1710370 is a reply to message #1710319] |
Tue, 06 October 2015 09:40 |
Ed Merks Messages: 33258 Registered: July 2009 |
Senior Member |
|
|
Simon,
Yes, I'm not really sure how signatures work on the Mac either; I know
they changed the layout in Mars so that signatures work properly...
Your forum edit doesn't show up in my Thunderbird reader but I see
you're referring to
https://wiki.eclipse.org/EPP/Logging#Enable_additional_debug_output
I can't really understand how they define what ${eclipse.working.dir}
means for all platforms, i.e., for Mac it suggests, as you say, that
it's in the same folder as the executable (though it's wrong in the
document and should be ./Eclipse.app/Contents/MacOs/.options), but it
doesn't define where this is on Linux or Windows, presumably the same way...
It seems rather questionable to me because with a shared/read-only
installation such a location is read-only. I would have expected such
information to be stored in the configuration folder so that for a
read-only installation the user can have a place to modify it. I need
to find out more details about why it's this way, but I suppose it's
unlikely to change anymore...
Reading more about this, I wonder if your assumption might just be
wrong. In particular, from reading
http://help.eclipse.org/mars/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Ftasks%2Frunning_eclipse.htm
and looking at the documentation for the -debug flag it says:
If a file location is not given, the platform looks in the directory
that eclipse was started from for a file called ".options".
I think that means it looks in the folder specified by user.dir system
property, i.e., the current working directory. That just happens to be
the folder where the executable is located when you launch from an
icon/shortcut/app, but that's not generally the case. So if you really
want it always to use certain options, you should specify an Eclipse
Ini task to specify the -debug option and include in that task the
absolute location of the .options file.
On 06/10/2015 7:44 AM, Simon Laffoy wrote:
> Quote:
>> No, there's nothing for that yet. Aren't the contents of that folder
>> signed and therefore shouldn't be modified?
>
>
> Hmm, I don't know if they are or not. I do know though that there are
> occasions when an option file should be saved in the install directory
> (where the executable is). For example, see the "Enable additional
> debug output" paragraph of this article.
>
> Additionally, I know that the effect that I am trying to achieve works
> if I manually save the option file in the install directory after
> installation.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
| |
Re: ResourceCreation of .options file in Eclipse install Directory [message #1710486 is a reply to message #1710482] |
Wed, 07 October 2015 07:07 |
Ed Merks Messages: 33258 Registered: July 2009 |
Senior Member |
|
|
Simon,
Comments below.
On 07/10/2015 8:43 AM, Simon Laffoy wrote:
> Quote:
>> I think that means it looks in the folder specified by user.dir system
>> property, i.e., the current working directory. That just happens to be
>> the folder where the executable is located when you launch from an
>> icon/shortcut/app, but that's not generally the case.
>
>
> Just curious now, but can you give me some examples of when this is
> not the case? The two ways that I use to start Eclipse are both from
> that directory (clicking on the .app icon, or via the command line)
From a command-line, the current directory of the shell/command-line
process should remain the current directory of any launched executable.
>
> As we are a small company and we all use Mac I am just going to go
> with ${installation.location}/Eclipse.app/Contents/MacOS/.options.
> However, this does give me another problem to overcome. The website I
> linked to
> (https://wiki.eclipse.org/EPP/Logging#Enable_additional_debug_output)
> says that the -debug option in the eclipse.ini file must appear above
> the -vmargs line. How can I create a new Eclipse ini set up task which
> specifies where in the ini file the debug flag must go?
An Eclipse Ini task can have Vm either be true or false. In this case,
the -debug option is not a VM option. Of course if you are going to
provide such a task to set the -debug option, it's also easy to specify
where the .options file appears, i.e., you might specify
${user.home/.../.options) and have another task to puts the option you
want into that file... This way there is a single options file that can
be changed for all installations...
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
| |
Goto Forum:
Current Time: Mon Dec 09 04:59:28 GMT 2024
Powered by FUDForum. Page generated in 0.03583 seconds
|