反应本机:错误获取无效的文件名。无法添加

时间:2018-08-02 08:00:59

标签: react-native

在为Android生成版本时,我对React-native和遇到错误很陌生。

npm版本-5.6.0 反应本机-2.0.1 节点-v8.11.3

cd android && ./gradlew assembleRelease && cd ..

> :app:generateReleaseBuildConfig UP-TO-DATE :app:mergeReleaseShaders
> UP-TO-DATE :app:compileReleaseShaders UP-TO-DATE
> :app:generateReleaseAssets UP-TO-DATE :app:mergeReleaseAssets
> UP-TO-DATE :app:generateReleaseResValues :app:generateReleaseResources
> :app:mergeReleaseResources :app:recordFilesBeforeBundleCommandRelease
> :app:bundleReleaseJsAndAssets UP-TO-DATE
> :app:generateBundledResourcesHashRelease
> a80585d59325c208e3d120fe613639e73132576ef0e4e85a5de149e5d64c9e16
> :app:processReleaseManifest UP-TO-DATE :app:processReleaseResources
> /Users/ravindrayadav/Documents/ZupplerMobile/mayaflavorsofindia/android/app/build/intermediates/res/merged/release/drawable-mdpi/node_modules_zupplernative_node_modules_reactnativegoogleplacesautocomplete_images_powered_by_google_on_white.png:
> error: Invalid filename.  Unable to add.
> 
> :app:processReleaseResources FAILED
> 
> FAILURE: Build failed with an exception.
> 
> * What went wrong: Execution failed for task ':app:processReleaseResources'.
> > com.android.ide.common.process.ProcessException: Failed to execute aapt
> 
> * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
> 
> BUILD FAILED
> 
> Total time: 11.171 secs

1 个答案:

答案 0 :(得分:0)

删除android / app / src / main / res / drawable- *目录中的图像文件并重新构建