Command line utility to quickly synchronize console folder with TC

Discuss and announce Total Commander plugins, addons and other useful tools here, both their usage and their development.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
jackhab
Junior Member
Junior Member
Posts: 35
Joined: 2008-03-05, 09:36 UTC

Command line utility to quickly synchronize console folder with TC

Post by *jackhab »

I've made a command line utility to quickly synchronize external console current folder with the folder in one of Total Commander panels.

Run tccd to print current folders in the left and right panels.

Run "tccd l" or "tccd r" and "cd c:\left_or_right_folder" string will be sent to your current console window.

Utility page on Totalcmd.net
mikedepetris
Junior Member
Junior Member
Posts: 84
Joined: 2006-11-07, 16:36 UTC
Location: Trieste, Italy
Contact:

Re: Command line utility to quickly synchronize console folder with TC

Post by *mikedepetris »

... that is obviously down... can't wait to have a try
jackhab
Junior Member
Junior Member
Posts: 35
Joined: 2008-03-05, 09:36 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *jackhab »

I published it just a couple a days ago, it's sad seeing Totalcmd.net down.

Please, check the release on Github: https://github.com/jackhab/tccd/releases
adoeller
Junior Member
Junior Member
Posts: 82
Joined: 2011-05-23, 09:47 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *adoeller »

the path is not displayed/found on my installation
jackhab
Junior Member
Junior Member
Posts: 35
Joined: 2008-03-05, 09:36 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *jackhab »

adoeller wrote: 2022-10-10, 08:00 UTC the path is not displayed/found on my installation
What TC version do you run?
User avatar
nsp
Power Member
Power Member
Posts: 1804
Joined: 2005-12-04, 08:39 UTC
Location: Lyon (FRANCE)
Contact:

Re: Command line utility to quickly synchronize console folder with TC

Post by *nsp »

Same issue here. 10,10.51,10.52RC1/2 32/64bit .

I have a nircdmc version just for source :

Code: Select all

@echo off
nircmdc clipboard clear
nircmdc win sendmsg class TTOTAL_CMD 0x433 2029 0
nircmdc clipboard set "PUSHD ~q~$clipboard$~q"
nircmdc sendkeypress ctrl+v enter
and another script to set current path to new tab:

Code: Select all

@start "" %commander_path%\totalcmd64 /O /T /S "%CD%"
I maintain a commander_path env variable to refelct totalcommander installation folder.
jackhab
Junior Member
Junior Member
Posts: 35
Joined: 2008-03-05, 09:36 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *jackhab »

adoeller wrote: 2022-10-10, 08:00 UTC the path is not displayed/found on my installation
Hi adoeller
I made a new version which displays window handles for debug when launched as tccd d

Do you mind trying it and posting the output?
adoeller
Junior Member
Junior Member
Posts: 82
Joined: 2011-05-23, 09:47 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *adoeller »

hi, I tried your debug version and also the original version, and now with the 10.52rc2 they both show the panel path :)
pplupo
Member
Member
Posts: 102
Joined: 2019-12-02, 16:26 UTC
Location: Canada
Contact:

Re: Command line utility to quickly synchronize console folder with TC

Post by *pplupo »

Can you do the opposite? Create a new tab on the left or right with the current cmd path? Because I've already created a button that opens the target panel's path on cmd, but I'd really like to do the reverse. After using cmd and navigating to a different directory, I wish I could open it on TCMD's running process without overriding the open tabs (or overriding with a flag).
adoeller
Junior Member
Junior Member
Posts: 82
Joined: 2011-05-23, 09:47 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *adoeller »

you mean something like

Code: Select all

"C:\Program Files\totalcmd\TOTALCMD64.EXE" /O /T /R=%CD%
jackhab
Junior Member
Junior Member
Posts: 35
Joined: 2008-03-05, 09:36 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *jackhab »

adoeller wrote: 2022-10-10, 08:00 UTC the path is not displayed/found on my installation
Hi adoeller,

Is it possible that you run TC as Administrator and open a normal user console? In this case tccd will not be able to read the folders from TC window because it has lower privileges.
adoeller
Junior Member
Junior Member
Posts: 82
Joined: 2011-05-23, 09:47 UTC

Re: Command line utility to quickly synchronize console folder with TC

Post by *adoeller »

i normally do not run as admin. at the moment, it is working. :)
Post Reply