nikclayton / android-squeezer

Android SqueezeCenter / SqueezeBox remote control client.
https://nikclayton.github.io/android-squeezer/
Apache License 2.0
99 stars 41 forks source link

I want to fork the project, what IDE do I need? #633

Closed viertelb closed 4 years ago

viertelb commented 4 years ago

I have a good understanding of Java (OCP cert) but did not develop an own app yet. I want to customize Squeezer because I don't need most of the features of the user interface (GUI?). This would also greatly enhance my knowledge. Can someone point me to the setup I need to compile the code into a working app so I can strip the code from certain parts and then test it?

kaaholst commented 4 years ago

Start here

This will tell what to install and what to read to build Android apps. There are a bunch of other stuff besides Java you need to know, but don't let that scare you.

Then you also need the Squeezer code, which you can checkout from here. For that you need some knowledge of git and Github.

I you wish to contribute please read CONTRIBUTING.md

Happy coding :-)

viertelb commented 4 years ago

Thanks! I installed Android Studio, forked the project to my github account, cloned it to my local disk and imported this into Android Studio. I did not pick the .gradle file but just went with the whole folder, but I think it imported it as gradle project and downloaded a lot of SDK stuff. I am going to do a full tutorial on Android Studio and app development. But maybe you could point me to one shortcut: since I now have the whole thing imported I should be able to "run" it on an emulator. Which one do I pick?

kaaholst commented 4 years ago

Yes if it compiles (and syncs with gradle files) you should be able to run the app, either in an emulator or a USB connected device. Any supported device (min API level 19) should work.

viertelb commented 4 years ago

Thanks! I was able to run it in the emulator on two systems, an old Mac and a newer Windows 10 laptop (the mac was too slow with the emulator). There are some minor issues in the CONTRIBUTING.md:

~/.AndroidStudioPreview/config/codestyles

is actually ~/.AndroidStudio3.6/config/codestyles

and:

"In the "Select File or Directory to Import" dialog that appears, navigate to the directory that you fetched the Squeezer source code in to and select the build.gradle file that ships with Squeezer."

This section does not work since it comes up with an issue that the project cannot be created because it already exists. It works just by chosing the whole directory for import.

I also wonder, if "forking" is the way to go since this creates a forked repository on my github and I think for contributing to the original project I have to push changes to the original master, not my forked one. But that's not so important since I am not able to contribute anything usefull atm.

Now I was wondering how to get a grasp of the project. What is the main file? Is it created with "Gradle" and do I use Gradle to make changes? How does it work?

viertelb commented 4 years ago

Ok, so Gradle is "just" build management. If I want to change the App I can just change the code and leave the Gradle part as is. I think. But I still can not find a "main" file in the code. I would think that java/uk.org.ngo.squeezer is the main code part and the class Squeezer sounds like a starter. Can someone point me to a book that would be best appropriate to this kind of development?

EDIT: Ok, there is a common base class for all activities named BaseActivity. I am going to search for a UML plugin to make a diagram.

viertelb commented 4 years ago

So I found several plugins for Android Studio that suppose to create UML files for projects, but none of them seem to work (at all) or are able to create something with the Community Edition of AS. It's probably a bit annoying, my way of using the "issues" tab here. I will delete it.