hehonghui / hehonghui/AndroidEventBus

Proguard Instructions

Open
#12 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
1.6k
Forks
390
PR merge metrics
No merged PRs in 30d

Description

Hey, I just thought I would let you know. If you're using Proguard with this library methods with the @Subscriber annotation may get compiled out of your app. So none of the event handling works - the methods aren't even there to respond. Here is what I added to the proguard rules file:

-keep class org.simple.** { *; }
-keep interface org.simple.** { *; }
-keepclassmembers class * {
    @org.simple.eventbus.Subscriber <methods>;
}

This keeps any methods that have the Subscriber annotation and the event handling works. I thought you might want to add this to your readme for others who would use the library.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the project's README and review the existing usage and configuration guidance for AndroidEventBus. Add the provided ProGuard rules and explain that they preserve methods annotated with @Subscriber; the documentation is done when users can apply the rules and understand why event handling otherwise fails.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java
Domain
documentation, mobile
Issue type
Documentation
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.