Skip to content

Latest commit

 

History

History
36 lines (26 loc) · 2.15 KB

WindowsDevSetup.md

File metadata and controls

36 lines (26 loc) · 2.15 KB

Developing ODK Collect on Windows

Overview

Most ODK devs are using OS X or Linux. Occasionally problems surface for Windows users due to code changes or tool changes. Such problems commonly include file path separators and file permissions differences from Linux/OSX. However in general it is possible to develop ODK using Android Studio on Windows.

Known Issues

Current Workarounds

  • Firebase Perf: disable with the following modifications

build.gradle: comment out the line that looks like:

    classpath 'com.google.firebase:perf-plugin:1.3.1'

collect_app/build.gradle: comment out the two firebase-perf lines that look like:

    apply plugin: 'com.google.firebase.firebase-perf'
    implementation 'com.google.firebase:firebase-perf:19.0.2' 

Configuring Android Studio for Windows

  • Change line endings to Unix. Settings > Editor > Code Style > General (tab) > Line Separator :: Unix and Mac OS (\n)
  • Configure the Terminal environment settings for Java: Settings > Tools > Terminal JAVA_HOME=C:/Program Files/Android/Android Studio/jre
  • Accept SDK licenses if necessary. Run from the Terminal in Android Studio using your own username AppData path: "C:\Users\<username>\AppData\Local\Android\Sdk\tools\bin\sdkmanager.bat" --licenses
  • To be able to run / debug tests using Android Studio, edit the JUnit configuration to use a classpath file instead of a bloated classpath string (which maxes out the tiny Windows limit for environment variables): Run > Edit Configurations... > (left pane)Templates > Android JUnit > (right pane)Shorten command line: classpath file

Configuring Git for Windows