Hi all,
it's tricky to find out if this has been discussed before, because of the many "false" hits concerning directory synchronization.
What I am looking for is entirely different: to integrate the unix-like "sync" command (flush file system write buffers). The exe itself is available here:
http://technet.microsoft.com/en-en/sysinternals/bb897438.aspx
Has anybody alreeady integrated this, esp. with a few appropropriate button designs for the different possible actions? I guess these two would cover 95% my needs, and save lots of mouseclicks for safely ejecting a USB stick.
sync "active" drive
sync "active" drive and eject
thx for tips...
integration of unix-like sync command
Moderators: Hacker, petermad, Stefan2, white
How do you want to integrate that tool? Just add it onto buttonbar, assign a hotkey or alias and call when you need it...
If you're creating buttonbar button or usercommand, there is no way to pass drive letter, but you can create batch file that will extract drive letter from passed path. So, use theese commands to pass active and passive panel's path:
And your batch should be the following:
(type full path to BAT in commands and place BAT near the EXE)
If you're creating buttonbar button or usercommand, there is no way to pass drive letter, but you can create batch file that will extract drive letter from passed path. So, use theese commands to pass active and passive panel's path:
Code: Select all
Command=Sync.bat
Parameters=%P
Code: Select all
Command=Sync.bat
Parameters=%T
Code: Select all
@start "%~dp0\Sync.exe" %~d1
For now, I have put in default.bar:
But coming to think of it, this would probably best be placed in the (right-click) context menu of the Drive buttons. I understand this is a Windows functionality, not TC, correct?
Code: Select all
button29=C:\Program Files (x86)\totalcmd\TOTALCMD.EXE,37
cmd29=C:\Windows\system32\sync.exe
param29=-r
path29=C:\Windows\system32\
menu29=SyncRemovableDrives