capacitor-assets
capacitor-assets copied to clipboard
Parameter --copy not working when custom path to resources is used
cordova-res -v
0.15.1
File structure:
-android
-theme
-dark
-resources
-icon.png
-splash.png
With upper file structure, using command
cordova-res android --resources themes/dark/resources --skip-config --copy
I get a lot of errors like this and fileas are not copied:
Error occurred while copying resources/android/splash/drawable-land-mdpi-screen.png
In verbose mode I can see that wrong path is used for generated resource files.
cordova-res:native Copying generated resource from 'resources/android/splash/drawable-land-mdpi-screen.png' to 'android/app/src/main/res/drawable-land-mdpi/splash.png'
The cause of problem is, that paths to resource files are defined in constants here: https://github.com/ionic-team/cordova-res/blob/b6c1fd030daa12717b605655a1f1637d59f6eef4/src/native.ts#L68-L71
and custom path defined in --resources parameter is not used.