Working with command line (complexity for TC user)

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
Joss
Posts: 21
Joined: 28 Nov 2012 18:56

Working with command line (complexity for TC user)

Post by Joss »

Hi,

Sorry for my English, it's not my native language.

I'm TC user and now try to use XYplorer.
I could not find how I can run an app from command line and pass arguments (full file names from both panels) to it.

Use case - how I did it in TC (e.g. I want to compare two files or folders with Araxis Merge app):

1) Wrote "merge.exe " in TC command line. [command line looks like > merge.exe]
2) Selected first file on a left panel and pressed Ctrl-Enter [> merge.exe file1.cpp]
3) Selected second file on a right panel and pressed Shift-Ctrl-Enter [> merge.exe file1.cpp d:\test\file2.cpp]
3) Pressed Enter

Is it possible in XYplorer? All that I can it write "!merge.exe" in address line, then copy full file name from a panel to clipboard, past it to address line. But how can I add second argument (a file from another panel)?

Thanks!

highend
Posts: 14953
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Working with command line (complexity for TC user)

Post by highend »

Create a button for it / a catalog entry or anything you want.

Code: Select all

$inactiveItem = get("Item", i);
	run """D:\Users\Highend\Tools\Beyond Compare\BCompare.exe"" ""<curitem>"" ""$inactiveItem""";
Change the path to your compare utility to fit your needs.

It will take the current focused file from the inactive pane and compare it with the current selected from the active one.
One of my scripts helped you out? Please donate via Paypal

serendipity
Posts: 3360
Joined: 07 May 2007 18:14
Location: NJ/NY

Re: Working with command line (complexity for TC user)

Post by serendipity »

These variables will also work:
Pane 1 item:

Code: Select all

<get item 1>
Pane 2 item:

Code: Select all

<get item 2>

Joss
Posts: 21
Joined: 28 Nov 2012 18:56

Re: Working with command line (complexity for TC user)

Post by Joss »

Thanks guys!

highend
Posts: 14953
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Working with command line (complexity for TC user)

Post by highend »

So you can combine it to only one line:

Code: Select all

run """D:\Users\Highend\Tools\Beyond Compare\BCompare.exe"" ""<get item 1>"" ""<get item 2>""";
Thanks serendipity!
One of my scripts helped you out? Please donate via Paypal

Post Reply