Skip to content

Latest commit

 

History

History
66 lines (51 loc) · 2.75 KB

README.md

File metadata and controls

66 lines (51 loc) · 2.75 KB

Bintray

Table of Contents generated with DocToc

maoni-github aims at sending the valuable feedback of your app users to the specified Github repository (as a Github issue).

Getting started

Add this to your build.gradle:

  dependencies {
    implementation('org.rm3l:maoni:10.0.0@aar') {
        transitive = true
        //Needed because of https://github.com/rm3l/maoni/issues/294
        exclude module: 'unspecified'
    }
    implementation('org.rm3l:maoni-github:10.0.0@aar') {
        transitive = true
        //Needed because of https://github.com/rm3l/maoni/issues/294
        exclude module: 'unspecified'
    }
  }

And set it as the listener for your Maoni instance:

    //Customize the maoni-github listener, with things like your user personal Access Token on Github
    final org.rm3l.maoni.github.MaoniGithubListener listenerForMaoni = 
            new org.rm3l.maoni.github.MaoniGithubListener(...);
    
    new Maoni.Builder(MY_FILE_PROVIDER_AUTHORITY)
        .withListener(listenerForMaoni) //Callback from maoni-github
        //...
        .build()
        .start(MaoniSampleMainActivity.this); //The screenshot captured is relative to this calling context 

You're good to go! Maoni will take care of validating / collecting your users' feedbacks and call maoni-github as needed.

Caveats

At this time, the Github API does not provide any ways to upload images or files to issues created. As such, the capability to attach screen captures and application logs to user feedback is not supported by maoni-github. Please note however that you can always provide your own callback implementation by extending MaoniGithubListener class and overriding its onSendButtonClicked(Feedback) method, so as to:

  1. upload the feedback attachments on any remote services of your choice;
  2. then update the Feedback object to include the attachments URLs;
  3. and call super.onSendButtonClicked(Feedback) to create the issue on your Github repo.

Credits

This is written in the excellent Kotlin programming language, and leverages some other excellent Open-Source libraries: