Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 231615 - RemoteLauncher ignores working directory for before/after scripts.
Summary: RemoteLauncher ignores working directory for before/after scripts.
Status: CLOSED FIXED
Alias: None
Product: PTP
Classification: Tools
Component: Remote Tools (show other bugs)
Version: 2.0.1   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Daniel Felix Ferber CLA
QA Contact: Greg Watson CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-12 13:49 EDT by Everton Rufino Constantino CLA
Modified: 2011-05-14 06:34 EDT (History)
0 users

See Also:


Attachments
This patch solves the problem making sure that before each script is executed it 'cd' to the actual working directory. (1.58 KB, patch)
2008-05-12 13:50 EDT, Everton Rufino Constantino CLA
g.watson: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Everton Rufino Constantino CLA 2008-05-12 13:49:20 EDT
At the "Launch" tab I can define a script that will be run before my application and a script that will run after the application is terminated. 

The expected behavior is that the scripts are executed in the working directory, however this is not the case. 

To reproduce the error just use a script that prints it's working directory after and before and saves the result in a temporary place, like for example:

'pwd > /tmp/before.txt'

and

'pwd > /tmp/after.txt'

Use the "Synchronize" tab to download the files, making sure that the plugin is set to not cleanup files after execution. 

The result is that the scripts are executed at the login directory and not at the working directory.
Comment 1 Everton Rufino Constantino CLA 2008-05-12 13:50:52 EDT
Created attachment 99763 [details]
This patch solves the problem making sure that before each script is executed it 'cd' to the actual working directory.
Comment 2 Greg Watson CLA 2008-05-13 09:47:10 EDT
Applied to 2.0 and HEAD.
Comment 3 Everton Rufino Constantino CLA 2008-05-21 13:44:38 EDT
Works for me.