Author Topic: Relative paths  (Read 15942 times)

kalekseishaken

  • Newbie
  • *
  • Posts: 2
    • View Profile
Relative paths
« on: August 02, 2011, 01:08:09 »
I have installed multi Commander in a folder called

     {DriveLetter}:\pUtilities\MultiCommander

When I press a button called ProgEditor, I want it to use the programmers editor found in

     {DriveLetter}:\pUtilities\fastEditor

How do I declare a relative drive or path (relative of course to where the Multi Commander application executed from?

Thanks,
Kalek Seishaken

Mathias (Author)

  • Administrator
  • VIP Member
  • *****
  • Posts: 4409
    • View Profile
    • Multi Commander
Re: Relative paths
« Reply #1 on: August 02, 2011, 10:01:46 »
File Editor Setup dialog when configuring what file editor to use. Type in a path that are relative to the installation path of MC.

for your example that would be

eg  "..\fastEditor\fastEditor.exe"


kalekseishaken

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Relative paths
« Reply #2 on: August 02, 2011, 18:31:01 »
Thanks for the response, that does not appear to work.

Let me ask you this. Is there a constant for the path of the application (in other words the path where Multi Commander is located)?

For example, the path that is in focus can be referred to as {focusfilepath}.

If there is a similar constant for the application path, then that would pretty much solve the problem. The editor is one that I wrote and it is a standalone executable. I even tried creating a folder for it under the MultiCommander\Extensions folder, and I just cannot get it to execute.

Multi Commander appears to be very well thought out, so I am assuming that it is something I am missing.

Sincerely,
Kalek Seishaken

Mathias (Author)

  • Administrator
  • VIP Member
  • *****
  • Posts: 4409
    • View Profile
    • Multi Commander
Re: Relative paths
« Reply #3 on: August 02, 2011, 20:16:51 »
No there is no constant for that.. I might add some for the next release.

You can try to edit the config file manuall.

"Menu > Go to > config folder" and  then edit MultiCommander.xml

The find the editors tag and change that

eg

<editors>
    <editor name="Notepad2" cmd="..\n2\notepad2.exe" parameters="${filepath}" ext="*"/>
</editors>

I got it working with notepad2

Mathias (Author)

  • Administrator
  • VIP Member
  • *****
  • Posts: 4409
    • View Profile
    • Multi Commander
Re: Relative paths
« Reply #4 on: August 14, 2011, 11:33:52 »
From build 814 it is now possible to specify the ${mcinstallpath} tag in the editor filepath field.

So "${mcinstallpath}\..\MyEditor\Editor.exe" Will now work. Even when running from USB.