简体   繁体   中英

How to avoid using + in version number with SQLiteAssetHelper

I am using the SQLiteAssetHelper class to manage an SQLite database in my app.

To do this I have followed the instructions on how to use SQLiteAssetHelper on GitHub, which is to add compile 'com.readystatesoftware.sqliteasset:sqliteassethelper:+' to my dependencies in my build.gradle file.

However, when I do this, android studio gives me a yellow warning, which says avoid using + in version numbers; can lead to unpredictable and unrepeatable builds avoid using + in version numbers; can lead to unpredictable and unrepeatable builds

Sounds ominous *Gulp*

but this GitHub page, which I will post below, doesn't offer a version number, it just says to add compile 'com.readystatesoftware.sqliteasset:sqliteassethelper:+'

Should I just leave the +? or is there a better way to do this?

https://github.com/jgilfelt/android-sqlite-asset-helper

If you click on the releases tab , you can see that the most recent release is 2.0.1. It is better that you specify this explicitly in order to have predictable builds.

Use

compile 'com.readystatesoftware.sqliteasset:sqliteassethelper:2.0.1'

This site - "Gradle, please" - can be helpful sometimes.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM