@GetMem
say you have project file B1.pas, B2.pas in folder /home/user/B and C1.pas in /home/user/C and C2.pas in /home/user/C/extra.
publish target is /home/user/publish.
folders /home/user/B, /home/user/C and /home/user/C/extra should not be copied to /home/user/publish, only the files B1.pas, B2.pas, C1.pas, C2.pas should be copied to /home/user/publish.
now B1, B2, C1 and C2 are in the publish folder. to work you just need to update the file name value for these files in the project lpi file in the Units section for each corresponding entry.
the exported project is no longer equivalent to the original one and that is fine. but it compiles also on a different machine given i have the same packages installed.
note: i would not copy but the files in the project inspector tree. do not agree with latest post from BrainChemistry
from a business perspective with publishing i make something formal or bring it to another level, in this case my possible garbage notes from the main directory should not be passed along.
the export should concentrate only on the files in project inspector - nothing else. the target is to have a folder that compiles in any computer with same dependencies and the executable is the same.
this of course is more difficult as based on the file name you would need to pick the corresponding lpr, lps, ico ... files.
ps. not ridiculous
. based on SOLID the best classes do not depend on other classes. pure functions? so i can use my class in several projects.
have a project to test and develop this class and another project where i am slowly integrating this class. i will not create a package immediately.