I am using gradle to create an android application. I copy several files and folders to the resource folder. I ran into a problem that some files may have a file name that is too long, as well as folders (aapt cannot handle file names longer than 100 characters).
Therefore, I rename the files during the copy operation as follows:
copy { from('A') into('B') rename ('too-long-filename', 'shorter-filename') rename ('too-long-directoryname', 'shorter-directoryname') }
However, this works fine for files, but does not work for directories. Is there a special command to achieve renaming while copying using gradle?
The error says:
Error code: 1 Output: /home/curiosity/AndroidStudioProjects/App/build/..if directory names are too long .. /: error: invalid directory name, could not be added.
source share