0
0
mirror of https://github.com/mediathekview/zapp.git synced 2024-09-19 20:02:17 +02:00
zapp/CONTRIBUTING.md

2.9 KiB

How to contribute

How to open an issue

If you found a bug, please specify the version of the app, you phone or tablet model and your Android version. This will help to track down the problem much fater.

How to add / change / fix code

  1. If you plan to make a significant change to the codebase, please create an issue first. This way we can discuss if and how and for which version your issue can be resolved best. For minor changes like correcting typos you don't need to create an issue first. Don't be afraid to ask if you have any questions about contributing to Zapp.

  2. Fork the Zapp repository on GitHub, because you will have no write access on the original repository.

  3. Create a branch you will use for the feature or fix. Read a couple of tips on how to do pull requests.

  4. Do the coding for your feature or fix. Use proper commit messages. Follow this styleguide when in doubt (except prefixing member variables and using spaces for indentation).

  5. Test your changes on an actual device or an emulator. If you added a channel run the JsonChannelListTest.

  6. Fix any lint errors. Run Analyze > Inspect Code > Whole project and make sure no errors or warnigs show up. Only suppress warnings if you know what you are doing.

  7. Create a pull request on GitHub.

How to build

Zapp is an Android project build with Android Studio. To build it on your machine make sure to install the most current version of Android Studio bundled with the Android SDK.

Once installed you can check out the development version of Zapp clicking File > New > Project from Version Control > GitHub. Enter your credentials. Now you can enter the Zapp repository url of your fork (https://github.com/[yourname]/zapp) and the directory you want the project to be saved to.

Now you should be ablte to build Zapp and run it on your device or do any other Android Studio operation.

How to add a new channel

  1. Edit channels.json to contain your channel. The rules are:
  • id must be lowercase letters (no umlauts), numbers and underscore only
  • id has to be unique
  • a long name may contain soft hyphens to improve word breaks
  • stream_url has to be the full url to the m3u8 manifest (f4m won't play)
  • logo_name has to start with channel_logo_
  • only define subtitle if there are multiple channels with the same name/logo
  • color has to be the darkest of the vibrant logo colors
  1. Run JsonChannelListTest and make sure all tests pass.
  2. Test the changes on an actual device (emulators may have trouble with video playback).