I use for example library Sweet Alert Dialog. I want to modify this library by adding text size customization to library/src/main/java/cn/pedant/SweetAlert/SweetAlertDialog.java
.
public SweetAlertDialog setTitleText (String text, int size) {
mTitleText = text;
int height = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, size, getResources().getDisplayMetrics());
if (mTitleTextView != null && mTitleText != null) {
mTitleTextView.setText(mTitleText);
mTitleTextView.setTextSize(height);
}
return this;
}
Now I want to test this library and use it if it does what it should do.
I need that one time explanation to get it. At the moment GitHub
is a little bit confusing.
UPDATE
I have added this library via
dependencies {
compile 'cn.pedant.sweetalert:library:1.3'
}
Is there any way to just make your own compile path and test it? After branching the library or so?
Open your web browser, navigate to the GitHub repository you want to clone, and then copy/paste its URL into the Android Studio dialog. Specify the local directory where you want to store the cloned repository. Give this directory a name, and then click 'Clone. '
The quickest way to obtain the library is to download it as ZIP file from GitHub.
Steps:
See below:
To make changes to Sweet Alert Dialog, we will import it into Android Studio.
Steps:
sweet-alert-dialog-master.zip
file to disk e.g. c:\sweet-alert-dialog-master
c:\sweet-alert-dialog-master
folder and click Ok.If the changes made to the Sweet Alert Dialog meet your requirements, we can proceed to use the Android archive (*.aar) file in our project.
Steps:
c:\sweet-alert-dialog-master\library\build\outputs\aarlibrary-release.aar
file in the libs
directory (create it if needed) of your project.Add the repositories section in the app\build.gradle
file:
repositories {
flatDir {
dirs 'libs'
}
}
Add the following line to the dependencies section:
compile (name: 'library-release', ext:'aar')
Now the Sweet Alert Dialog contained in the Android archive file can be used in your app.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With