NativeScript Blog

Workaround: Windows: File path too long - keep below 240 characters

Dan Wilson March 9, 2016

Find a workaround to the File path too long - keep below 240 characters issue on Android builds on the Windows platform.

Recently, NativeScript users who develop on the Windows platform have been getting an error to the effect of "File path too long - keep below 240 characters" or even "Command D:\some\path\projectname\platforms\android\gradlew.bat failed with exit code 1".

This error is caused by how Gradle (used in Android Builds) handles builds. In short, gradle makes a unique build file name by including the names of all plugins in your application that have a platform/android component.

It's easy to run over the file path character count limit in windows.

Join the conversation

Share your feedback or ask follow-up questions below.