[Implemented] New environment variable needed
Moderators: Hacker, petermad, Stefan2, white
[Implemented] New environment variable needed
After starting testing the x64 version of TC 8.0 I have had to make a lot of changes to my setup, everywhere where I start Total Commander in a new process.
In usercmd.ini and buttonbars I have used %COMMANDER_PATH%\TOTALCMD.EXE in 100's of places. They are all obsolete with the x64 version where it has to be %COMMANDER_PATH%\TOTALCMD64.EXE
I can off course change that in my *.ini and *.bar files, but then I cannot use the same files with the 32bit version, which I cannot discharge for a long time because of missing 64bit plugins.
So I suggest that we get a new environment variable:
%COMMANDER_PROGRAM%
to replace either: %COMMANDER_PATH%\TOTALCMD.EXE and %COMMANDER_PATH%\TOTALCMD64.EXE
or to replace just: TOTALCMD.EXE and TOTALCMD64.EXE.
In usercmd.ini and buttonbars I have used %COMMANDER_PATH%\TOTALCMD.EXE in 100's of places. They are all obsolete with the x64 version where it has to be %COMMANDER_PATH%\TOTALCMD64.EXE
I can off course change that in my *.ini and *.bar files, but then I cannot use the same files with the 32bit version, which I cannot discharge for a long time because of missing 64bit plugins.
So I suggest that we get a new environment variable:
%COMMANDER_PROGRAM%
to replace either: %COMMANDER_PATH%\TOTALCMD.EXE and %COMMANDER_PATH%\TOTALCMD64.EXE
or to replace just: TOTALCMD.EXE and TOTALCMD64.EXE.
Last edited by petermad on 2021-05-29, 20:24 UTC, edited 2 times in total.
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Obviously you can. You can rename it yourself. And I would guess that if you had both in the same dir, you would write a script to automatically launch the correct one. And such script can set a variable if needed. I think that changing app name is unnecessary mess.Sir_SiLvA wrote:No! that way you cant have 32bit and 64bit in one dir...m^2 wrote:I think it would be better if Christian kept calling TC totalcmd.exe.
@pertermad: if you dont use tc 32bit anymore why not just rename tc64.exe to tc.exe?
ps: tc=totalcmd
- ghisler(Author)
- Site Admin
- Posts: 50625
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
You can just rename totalcmd64.exe to totalcmd.exe if you don't want to run the 32-bit and 64-bit versions in parallel, or better create a hard link from totalcmd.exe to totalcmd64.exe (e.g. using the tool junction.exe from www.sysinternals.com ).
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
2Sir_SiLvA
2ghisler(Author)
If I rename do I also have to rename TOTALCMD64.EXE.MANIFEST ?
Anyway - renaming seems to simply be an unpractical workaround, that doesn't even take into account that the 32bit and 64bit versions can be installed in the same dir.
As i wrote:@pertermad: if you dont use tc 32bit anymore why not just rename tc64.exe to tc.exe?
So yes I do use the 32bit version. I also have a Win XP machine - it is much more practical if I can use the same .ini and .bar files with both computers.I cannot use the same files with the 32bit version, which I cannot discharge for a long time because of missing 64bit plugins.
2ghisler(Author)
Well, I can, but what about the users that use my extended menus - they would have to be instructed to do the same - a little akward. And what about updates - will the installer automatically rename totalcmd64.exe to toltalcmd.exe when it sees that it is present (and not being the 32bit exe in the same dir).You can just rename totalcmd64.exe to totalcmd.exe if you don't want to run the 32-bit and 64-bit versions in parallel,
If I rename do I also have to rename TOTALCMD64.EXE.MANIFEST ?
Anyway - renaming seems to simply be an unpractical workaround, that doesn't even take into account that the 32bit and 64bit versions can be installed in the same dir.
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
I support the suggestion for new internal variable like %COMMANDER_PROGRAM% since it's much easier to replace one string in all configuration files then the adaptation of the one instance of each config file for both 32 and 64 bit Total Commander installed in same directory.
Donate for Ukraine to help stop Russian invasion!
Ukraine's National Bank special bank account:
UA843000010000000047330992708
Ukraine's National Bank special bank account:
UA843000010000000047330992708
Support++
Especially if you are using a portable installation you may want to start the 32bit TC version on 32bit systems.
One additional environment variable like %COMMANDER_PROGRAM% saves you the effort to install and maintain 2 versions in different installation paths.
Regards
Holger
Especially if you are using a portable installation you may want to start the 32bit TC version on 32bit systems.
One additional environment variable like %COMMANDER_PROGRAM% saves you the effort to install and maintain 2 versions in different installation paths.
Regards
Holger
Make our planet great again
- Samuel
- Power Member
- Posts: 1930
- Joined: 2003-08-29, 15:44 UTC
- Location: Germany, Brandenburg an der Havel
- Contact:
Support++
Otherwise I need to maintain 2 buttons:
Otherwise I need to maintain 2 buttons:
Code: Select all
TOTALCMD#BAR#DATA
%Commander_Path%\TOTALCMD.EXE
/S=S "%X%Z%P" "%T"
%Commander_Path%\TOTALCMD.EXE,32
sync32
%Commander_Path%
0
-1
Code: Select all
TOTALCMD#BAR#DATA
%Commander_Path%\TOTALCMD64.EXE
/S=S "%X%Z%P" "%T"
%Commander_Path%\TOTALCMD64.EXE,32
sync64
%Commander_Path%
0
-1
2Sir_SiLvA
2Peter_Mad
Can you fix title typo in environtment
I would not recommend to install 32 and 64 bit version in same directory. Keep it separate and you can keep the old name TOTALCMD.EXE.Sir_SiLvA wrote:No! that way you cant have 32bit and 64bit in one dir...
2Peter_Mad
Can you fix title typo in environtment
TC plugins: Autodesk 3ds Max / Inventor / Revit Preview, FileInDir, ImageMetaData (JPG Comment/EXIF/IPTC/XMP), MATLAB MAT-file Viewer, Mover, SetFolderDate, Solid Edge Preview, Zip2Zero and more
It doesn't magically solve everything, but instead brings new problems, although I admit that's because not everyone adopted the same approach with appending "64". Did you see related thread about OpenSSL dlls? How would you solve that?Sir_SiLvA wrote:the names as they are now with a 64 are the best solution.
I don't think you really need both TCs in same directory, correct me if I'm wrong. What is needed are shared settings. And it should be possible even with separate TCs. Things like button bar files can be put somewhere where they can be referenced using environment variables. Plugins should store their settings in same directory where TC ini files are. A lot of them don't, but if their authors find time to produce 64-bit versions, they could fix this too.
The only real problem I see, and I must admit it's not a small one, is that it requires user to make some configuration changes, possibly a lot of them, which is of course bad. But it should be one-time thing. And maybe some nice tool to help with that could be made?
I dont think a new Variable wasting Virtual Space solves anything as in the long run
- If Chris doesnt come up with a clever way -
you will need 2 Ini-Files (one for 32/64 Bit each) as 64Bit needs 64Bit-Plugins
shared things like Gui, Copy-Etc-Options can be shared with RedirectSection
So id prefer if for sections like Plugins there would be an Option called
RedirectSection64 (only read by TC64 ofc and overriding RedirectSection)
i dont get it how someone can waste so much space with
But to solve that Problem as Pointed out its easier to use 2 seperate directories for 32/64Bit TC with using RedirectSection...
(wich would solve also the openssl-nonesense...)
that could look ie
TotalCommand
-> TC32Bit
-> TC64Bit
-> Inis
-> PlugIns
me, I prefer 32 & 64 bit in one folder and a 64 at all 64Bit files to easily see wich are 64Bit and wich are not cause compared to 16Bit 32Bit wont die out that fast...
- If Chris doesnt come up with a clever way -
you will need 2 Ini-Files (one for 32/64 Bit each) as 64Bit needs 64Bit-Plugins
shared things like Gui, Copy-Etc-Options can be shared with RedirectSection
So id prefer if for sections like Plugins there would be an Option called
RedirectSection64 (only read by TC64 ofc and overriding RedirectSection)
i dont get it how someone can waste so much space with
but im surly the only one that doesnt understand that nonesense...In usercmd.ini and buttonbars I have used %COMMANDER_PATH%\TOTALCMD.EXE in 100's of places
But to solve that Problem as Pointed out its easier to use 2 seperate directories for 32/64Bit TC with using RedirectSection...
(wich would solve also the openssl-nonesense...)
that could look ie
TotalCommand
-> TC32Bit
-> TC64Bit
-> Inis
-> PlugIns
me, I prefer 32 & 64 bit in one folder and a 64 at all 64Bit files to easily see wich are 64Bit and wich are not cause compared to 16Bit 32Bit wont die out that fast...
Hoecker sie sind raus!
Just a thought:So id prefer if for sections like Plugins there would be an Option called
RedirectSection64 (only read by TC64 ofc and overriding RedirectSection)
Code: Select all
pluginbasedir=%COMMANDER_PATH%\plugins%PROCESSOR_ARCHITECTURE%
[PackerPlugins]
RedirectSection=%COMMANDER_PATH%\wincmd_Plugins%PROCESSOR_ARCHITECTURE%.ini
[ListerPlugins]
RedirectSection=%COMMANDER_PATH%\wincmd_Plugins%PROCESSOR_ARCHITECTURE%.ini
[FileSystemPlugins]
RedirectSection=%COMMANDER_PATH%\wincmd_Plugins%PROCESSOR_ARCHITECTURE%.ini
[ContentPlugins]
RedirectSection=%COMMANDER_PATH%\wincmd_Plugins%PROCESSOR_ARCHITECTURE%.ini
Holger