StfalconImageViewer
StfalconImageViewer copied to clipboard
Migration from JCenter
In may this library won't be available from JCenter: https://jfrog.com/blog/into-the-sunset-bintray-jcenter-gocenter-and-chartcenter/
Please migrate this library to some other repository
For anyone that wants to get rid of jcenter()
without having to migrate away from this library, you can compile this project yourself to an AAR file and include that in your dependencies.
- Clone this repo
- Build the AAR:
./gradlew :imageviewer:assembleRelease
- The AAR file can be found at
imageviewer/build/outputs/aar/imageviewer-release.aar
. Copy this intoapp/libs/
in your project. - Add this to your dependencies:
The AAR file does not include transitive dependencies, so you will need to include PhotoView yourselfimplementation files("libs/imageviewer-release.aar") implementation "com.github.chrisbanes:PhotoView:2.2.0"
- Subscribe to notifications on this issue so that you can get notified if this project ever moves to another repository and you can remove all of the above :)
Any updates? Will we get a Maven Central (or other repository) update for the library? Thank you for looking into this!
implementation 'com.github.omkar-tenkale:StfalconImageViewer:d11578fe3fd30c33a58b49978e3a9fd425291673'
EDIT: This works too
implementation 'com.github.stfalcon-studio:StfalconImageViewer:master-SNAPSHOT'
Use with maven { url 'https://jitpack.io' }
in project build gradle inallprojects { repositories { ...
block
Happy Coding 😁
implementation 'com.github.omkar-tenkale:StfalconImageViewer:d11578fe3fd30c33a58b49978e3a9fd425291673'
I just forked this repo and added to my project via Jitpack (https://jitpack.io/)
You can use the line above Else if you want to host this library yourslelf follow these steps
1.Fork this repo 2.Go to your forked repo eg https://github.com/omkar-tenkale/StfalconImageViewer 3. Create your own implementation string like above in format implementation com.github,my_user_name:StfalconImageViewer:d11578fe3fd30c33a58b49978e3a9fd425291673
The last part is commit hash,You can use a different commit hash for a diferent version.
4 Just paste this newly created string in your build gradle sync a few times took me 2-3 syncs
Done :)
You also need to add this line to build gradle
maven { url 'https://jitpack.io' }
My root build gradle file
buildscript {
repositories {
google()
jcenter()
mavenCentral()
}
dependencies {
classpath "com.android.tools.build:gradle:4.2.1"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
google()
jcenter()
maven { setUrl("https://jitpack.io") }
maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
For gradle plugin version 7.0.3, I need to edit settings.gradle to use the library from the jitpack repository.
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
jcenter() // Warning: this repository is going to shut down soon
maven { url "https://jitpack.io" }
}
}
@dncks1525 Remember that order matters. With such setup - library will still be downloaded from jCenter. I'd recommend to move it to the end
@omkar-tenkale I believe the jitpack.io repo is protected by authentication. If we try to download it from jitpack we get an authentication error. I am wondering if you have jitpack authentication already configured so it is working for you.
@brian-pinwheel No its public
@omkar-tenkale This is the URL that was computed when I included the library and when I tried to access it, I was met with an authentication prompt. Is the URL not computed correctly from the build or is the maven artifact repository private?
You tried using the new
implementation 'com.github.stfalcon-studio:StfalconImageViewer:v1.0.1'
@omkar-tenkale I was going off the readme of the repo. Should I be looking elsewhere for which version to use?
Also, do you make the current version public and password protect older versions? I would think if you were trying to use an authentication model you would want to password protect the latest version. I am a bit concerned about depending on a library that might make the version I'm using password-protected in the future.