2

Whenever I try to run this command

sh /opt/Aptana_Studio_3/AptanaStudio3.sh 

for the Aptana Studio 3 from root directory it shows that

/opt/Aptana_Studio_3/AptanaStudio3.sh: 3: /opt/Aptana_Studio_3/AptanaStudio3.sh: ./AptanaStudio3: not found

but when i go to the directory it is executed easily.

Since I made shortcut for the given file and it shows

there was error launching the application and so i think the error as in the above command could be the reason for this. If There is something else please let me know.

Code For Desktop Entry

[Desktop Entry]
Version=1.0
Encoding=UTF-8
Name=Aptana Studio 3
GenericName=Integrated Development Environment
Comment=Aptana Strudio 3 Integrated Development Environment
Exec=/opt/Aptana_Studio_3/AptanaStudio3.sh
TryExec=/opt/Aptana_Studio_3/AptanaStudio3.sh
Icon=/opt/Aptana_Studio_3/AS3.png
StartupNotify=true
StartupWMClass="Aptana Studio 3"
Terminal=true
Type=Application
MimeType=text/xml;application/xhtml+xml;application/x-javascript;application/x-php;application/x-java;text/x-javascript;text/html;text/plain
Categories=GNOME;Development;IDE;

So I need your help to figure this and make a working desktop entry for this program

2
  • Can you clarify a little bit? Do you mean when your current working directory is /root or when you are logged in as root it will not work? And when you cd to the directory and run AptanaStudio3.sh it does run? I think that's what you mean. Are you logged in root? Do you need to be? How did you log in root? I may be able to better answer your question with some clarity. Commented Apr 7, 2014 at 5:39
  • ohk.....I one terminal and then simply type the command i.e. sh ./opt/Aptana_Studio_3/AptanaStudio3.sh Then It Shows me the error no such file or Directory all these commands are without sudo.. Secondly when change directory to the folder and then run ./AptanaStudio3.sh it works perfectly Commented Apr 10, 2014 at 4:16

1 Answer 1

0

Open /opt/Aptana_Studio_3/AptanaStudio3.sh script.

sudo gedit /opt/Aptana_Studio_3/AptanaStudio3.sh

There should be the line (apparently, the 3rd) which actually launches Aptana Studio. Change it to /opt/Aptana_Studio_3/AptanaStudio3. The reason is there should be absolute path, not relative.

6
  • Please clarify. What does it show in the output? Commented Apr 9, 2014 at 4:24
  • ./opt/Aptana_Studio_3/AptanaStudio3: No such file or directory Commented Apr 10, 2014 at 4:14
  • Notice the dot before /opt. It means that this path is still relative and starts in the current directory. To make path absolute, just remove the dot. Commented Apr 10, 2014 at 4:19
  • ohk....thanx it working....fine..and also thanx for letting me know the this relative and absolute path system Commented Apr 10, 2014 at 4:23
  • If you want to know more, visit the link I just added. Commented Apr 10, 2014 at 4:38

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.