Pretty simple question, suppose my app will be installed as
myApp
+-- bin
+-- lib
I’d like to rename “lib” to “plugins” after installation, how can i do that?
There is a MoveFiles Element that might help, but no idea how to use it.
EDIT:
The problem here is, in my case, source files could be installed into different paths, this scenario described in here.
The only way I can figure out is to create two component groups and install them conditionally. However, using heat to harvest same subdir twice will cause ID conflicting, so I’m thinking to use different paths(e.g. lib and another-lib), and then rename one of the path back after installation, so this question arised…
I finally wrote a C++ program to extend
heatgenerated wxs with another directory structure. So we can decide which path to install under different situations. It worked just like changing name during installation.Here is the wxs file patched by my program. Basically it creates another directory
WEBIDRand different subdirs, then adds another component groupwebGroupfor later reference by condition element.You can do the same thing manually, but if there are thousands of files awaiting, and if they are frequently updating, maybe a program(or script) is a better choice.