How To Properly Configure Gradle Dependency Script in FIre

Hi Admin,

I would like to use Gradle script in Fire. May I know what is its proper steps? It seems like I cannot edit the script in Fire after created the gradle script in the project. I have to externally open it with text editor and edit it, below is the script I typed. But with this, it seems like still cant use those support library. Kindly advise.

//build.gradle
apply plugin: 'base’
configurations { compile }
clean { delete += “dependencies” }
task copyDeps(type: Copy) { from configurations.compile into new File(projectDir, “dependencies”) }
build.dependsOn copyDeps

// Add your dependencies below

repositories {
jcenter()
}

dependencies {
compile "com.android.support:support-compat:24.0.0”
compile "com.android.support:appcompat-v7:24.0.0”
compile "com.android.support:design:24.0.0”
}

Thank You.

Best Regards,
Thol Yong

For proper gradle support, you will want to use the latest Fire 8.3.95 or (better) the 8.4 beta.

Noted. Thank You. :slight_smile:

Hi Admin,

I just started using the latest 8.4 fire beta. It prompts me this error when I include gradle script. Any idea on how to solve this?

/Applications/Fire.app/Contents/Resources/XbuildTargets/RemObjects Software/Elements/RemObjects.Elements.Cooper.Common.targets (ResolveGradleReferences target) ->

    /Applications/Fire.app/Contents/Resources/XbuildTargets/RemObjects Software/Elements/RemObjects.Elements.Cooper.Common.targets: error : Gradle path is not set in CooperPaths.xml

Thank You

I have solved the problem by installing Gradle and set its gradle folder path in Fire.

Btw, may I know how to remove the reference added by gradle? I didnt the choice to remove the reference added by gradle if I accidentally added the unwanted reference.

Thank You.

just remove it from the grade file and rebuild (maybe do a clean, jic)