mirror of
https://codeberg.org/gitnex/GitNex.git
synced 2024-12-16 15:48:13 +08:00
Merge pull request 'update libs, fix required bugs after update libs, bump app ver' (#286) from update-libs into master
Reviewed-on: https://gitea.com/gitnex/GitNex/pulls/286
This commit is contained in:
commit
e35846ab51
@ -6,8 +6,8 @@ android {
|
||||
applicationId "org.mian.gitnex"
|
||||
minSdkVersion 21
|
||||
targetSdkVersion 29
|
||||
versionCode 90
|
||||
versionName "2.4.0"
|
||||
versionCode 100
|
||||
versionName "2.5.0-dev"
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
buildTypes {
|
||||
@ -20,31 +20,40 @@ android {
|
||||
//checkReleaseBuilds false
|
||||
abortOnError false
|
||||
}
|
||||
compileOptions {
|
||||
targetCompatibility = "8"
|
||||
sourceCompatibility = "8"
|
||||
}
|
||||
}
|
||||
|
||||
configurations {
|
||||
cleanedAnnotations
|
||||
compile.exclude group: 'org.jetbrains' , module:'annotations'
|
||||
}
|
||||
|
||||
dependencies {
|
||||
def lifecycle_version = "2.2.0"
|
||||
final def markwon_version = "4.1.1"
|
||||
final def markwon_version = '4.2.1'
|
||||
|
||||
implementation fileTree(include: ['*.jar'], dir: 'libs')
|
||||
implementation "androidx.appcompat:appcompat:1.1.0"
|
||||
implementation "com.google.android.material:material:1.2.0-alpha05"
|
||||
implementation "androidx.constraintlayout:constraintlayout:1.1.3"
|
||||
implementation "androidx.legacy:legacy-support-v4:1.0.0"
|
||||
testImplementation "junit:junit:4.12"
|
||||
testImplementation 'junit:junit:4.13'
|
||||
androidTestImplementation "androidx.test:runner:1.2.0"
|
||||
androidTestImplementation "androidx.test.espresso:espresso-core:3.2.0"
|
||||
implementation "com.github.vihtarb:tooltip:0.2.0"
|
||||
implementation "com.squareup.okhttp3:okhttp:3.12.1"
|
||||
implementation "com.google.code.gson:gson:2.8.5"
|
||||
implementation "com.squareup.okhttp3:okhttp:4.4.0"
|
||||
implementation "com.google.code.gson:gson:2.8.6"
|
||||
implementation "com.squareup.picasso:picasso:2.71828"
|
||||
implementation "com.amulyakhare:com.amulyakhare.textdrawable:1.0.1"
|
||||
implementation "com.squareup.retrofit2:retrofit:2.5.0"
|
||||
implementation "com.squareup.retrofit2:converter-gson:2.5.0"
|
||||
implementation "com.squareup.retrofit2:converter-scalars:2.5.0"
|
||||
implementation "com.squareup.okhttp3:logging-interceptor:3.12.1"
|
||||
implementation "org.ocpsoft.prettytime:prettytime:4.0.1.Final"
|
||||
implementation "com.vdurmont:emoji-java:4.0.0"
|
||||
implementation "com.squareup.retrofit2:retrofit:2.7.1"
|
||||
implementation "com.squareup.retrofit2:converter-gson:2.7.1"
|
||||
implementation "com.squareup.retrofit2:converter-scalars:2.7.1"
|
||||
implementation "com.squareup.okhttp3:logging-interceptor:4.4.0"
|
||||
implementation "org.ocpsoft.prettytime:prettytime:4.0.3.Final"
|
||||
implementation "com.vdurmont:emoji-java:5.1.1"
|
||||
implementation "com.pes.materialcolorpicker:library:1.2.5"
|
||||
implementation "io.noties.markwon:core:$markwon_version"
|
||||
implementation "io.noties.markwon:ext-latex:$markwon_version"
|
||||
@ -66,7 +75,7 @@ dependencies {
|
||||
implementation "androidx.lifecycle:lifecycle-extensions:$lifecycle_version"
|
||||
implementation "androidx.lifecycle:lifecycle-viewmodel:$lifecycle_version"
|
||||
implementation "com.github.HamidrezaAmz:BreadcrumbsView:0.2.9"
|
||||
implementation "commons-io:commons-io:2.6"
|
||||
implementation "commons-io:commons-io:20030203.000550"
|
||||
implementation "com.github.chrisbanes:PhotoView:2.3.0"
|
||||
implementation "com.pddstudio:highlightjs-android:1.5.0"
|
||||
implementation "com.github.barteksc:android-pdf-viewer:3.2.0-beta.1"
|
||||
|
@ -10,7 +10,7 @@ import androidx.annotation.NonNull;
|
||||
import androidx.appcompat.widget.Toolbar;
|
||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
import org.apache.commons.io.FilenameUtils;
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.mian.gitnex.R;
|
||||
import org.mian.gitnex.adapters.FilesDiffAdapter;
|
||||
import org.mian.gitnex.clients.RetrofitClient;
|
||||
@ -121,7 +121,7 @@ public class FileDiffActivity extends BaseActivity {
|
||||
}
|
||||
}
|
||||
|
||||
String fileExtension = FilenameUtils.getExtension(fileNameFinal);
|
||||
String fileExtension = FileUtils.getExtension(fileNameFinal);
|
||||
|
||||
String fileContentsFinalWithBlankLines = fileContentsFinal.replaceAll( ".*@@.*", "" );
|
||||
String fileContentsFinalWithoutBlankLines = fileContentsFinal.replaceAll( ".*@@.*(\r?\n|\r)?", "" );
|
||||
@ -140,9 +140,9 @@ public class FileDiffActivity extends BaseActivity {
|
||||
String binaryFileRaw = binaryFile[1].substring(binaryFile[1].indexOf('\n')+1);
|
||||
String binaryFileFinal = binaryFile[1].substring(binaryFileRaw.indexOf('\n')+1);
|
||||
|
||||
String fileExtension = FilenameUtils.getExtension(getFileNameFinal);
|
||||
String fileExtension = FileUtils.getExtension(getFileNameFinal);
|
||||
|
||||
if(appUtil.imageExtension(FilenameUtils.getExtension(getFileNameFinal))) {
|
||||
if(appUtil.imageExtension(FileUtils.getExtension(getFileNameFinal))) {
|
||||
|
||||
fileContentsArray.add(new FileDiffView(getFileNameFinal, appUtil.imageExtension(fileExtension), "", binaryFileFinal));
|
||||
}
|
||||
|
@ -30,7 +30,7 @@ import com.github.barteksc.pdfviewer.util.FitPolicy;
|
||||
import com.github.chrisbanes.photoview.PhotoView;
|
||||
import com.pddstudio.highlightjs.HighlightJsView;
|
||||
import com.pddstudio.highlightjs.models.Theme;
|
||||
import org.apache.commons.io.FilenameUtils;
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.mian.gitnex.R;
|
||||
import org.mian.gitnex.clients.RetrofitClient;
|
||||
import org.mian.gitnex.fragments.BottomSheetFileViewerFragment;
|
||||
@ -149,7 +149,7 @@ public class FileViewActivity extends BaseActivity implements BottomSheetFileVie
|
||||
|
||||
if(!response.body().getContent().equals("")) {
|
||||
|
||||
String fileExtension = FilenameUtils.getExtension(filename);
|
||||
String fileExtension = FileUtils.getExtension(filename);
|
||||
mProgressBar.setVisibility(View.GONE);
|
||||
|
||||
// download file meta
|
||||
|
Loading…
Reference in New Issue
Block a user