UploadToJitpack


Source link: https://github.com/nisrulz/UploadToJitpack

Upload to JitPack

Specs

Featured in

Show some ❤?


Base repository to demonstrate the process of uploading an aar/ jar to JitPack.

Blog Post : Guide to publishing your Android Library via JitPack

The process is as follows

  1. Create an Android project or open an existing one in Android Studio

  2. Init the project with git and also create a repo on Github for the same. Each step here onwards represent a commit and should be pushed to github.

  3. Create and add a new module and choose Android Library.

    Goto File>New>New Module.. and select Android Library.

  4. Implement your library code inside the library module you created in the last step.

  5. Next add the library module as a dependency to the app module.

    1. Goto File>Project Structure..
    2. Select app module in the sidebar
    3. Select the Dependencies tab
    4. At the bottom is a + icon, click that and select Module dependency and select your library module.
    5. Press apply or ok.
  6. Once project is synced, add the android-maven-gradle-plugin to classpath in build.gradle file at root project level.

 dependencies {

  classpath 'com.android.tools.build:gradle:2.1.2'
  ..
  ..
  // Setup the android-maven-gradle-plugin in the classpath
  classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
  ..
  1. Next, apply the android-maven-gradle-plugin to the build.gradle file at library module level. Also add the group variable.
 apply plugin: 'com.android.library'
// Required plugin in library module  apply plugin: 'com.github.dcendents.android-maven'
// Replace nisrulz with <your_github_username>  group='com.github.nisrulz'
  1. Create a release TAG in git
git tag -a 1.0 -m "v1.0" git push origin 1.0 
  1. Once everything is pushed and the release TAG is also pushed, goto https://www.jitpack.io/#username/reponame where replace username with your github username and reponame with the reponame of the android project.

  2. Select the release you would like to share by clicking the ‘Get It’ button next to the list of releases of your repository.

  1. Next the same page at Jitpack would show you how to use the library in your other android projects. Something like below

Selectable code

repositories {

  jcenter()
  maven {
 url “https://jitpack.io” 
}
 
}
 dependencies {

  compile 'com.github.nisrulz:awesomelib:1.0' 
}
  1. Let the world know of your AwesomeLib 😄
  • Add a readme that explains how to integrate and use your Awesome library
  • Add a license block as in this repo
  • Also include the JitPack badge provided by jitpack in your readme
  • Promote your lib on social media so that others can know about it.
  • Always add a working sample app in your project that demonstrates your library in use.
  • Add screenshots if possible in your readme.

If you found this example helpful or you learned something today and want to thank me, consider buying me a cup of ☕?

  • PayPal
  • Bitcoin Address: 13PjuJcfVW2Ad81fawqwLtku4bZLv1AxCL

License

Copyright 2016 Nishant Srivastava  Licensed under the Apache License, Version 2.0 (the "License");
 you may not use this file except in compliance with the License. You may obtain a copy of the License at
  http://www.apache.org/licenses/LICENSE-2.0  Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. 

Resources

ViewGroup backed by RecyclerView.Adapter = magic

A small library containing a wrapper/helper for the shared preferences of Android with ability to specify default values at top level.

An activity manager for Android.

Develop your Android applications in real-time. The changes you make are automatically applied to your running application. Works with real devices and emulators alike.

Android custom view to show progress of process.

Android toolbar with layout direction support.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes