Added pull message
This commit is contained in:
parent
b4391880ac
commit
7df6381813
@ -74,6 +74,7 @@ class TabState @Inject constructor(
|
|||||||
// migrate the code that uses this function
|
// migrate the code that uses this function
|
||||||
title: String = "",
|
title: String = "",
|
||||||
subtitle: String = "",
|
subtitle: String = "",
|
||||||
|
// TODO For now have it always as false because the data refresh is cancelled even when the git process couldn't be cancelled
|
||||||
isCancellable: Boolean = false,
|
isCancellable: Boolean = false,
|
||||||
refreshEvenIfCrashes: Boolean = false,
|
refreshEvenIfCrashes: Boolean = false,
|
||||||
refreshEvenIfCrashesInteractive: ((Exception) -> Boolean)? = null,
|
refreshEvenIfCrashesInteractive: ((Exception) -> Boolean)? = null,
|
||||||
|
@ -29,6 +29,8 @@ class MenuViewModel @Inject constructor(
|
|||||||
fun pull(pullType: PullType) = tabState.safeProcessing(
|
fun pull(pullType: PullType) = tabState.safeProcessing(
|
||||||
refreshType = RefreshType.ALL_DATA,
|
refreshType = RefreshType.ALL_DATA,
|
||||||
refreshEvenIfCrashes = true,
|
refreshEvenIfCrashes = true,
|
||||||
|
title = "Pulling",
|
||||||
|
subtitle = "Pulling changes from the remote branch to the current branch"
|
||||||
) { git ->
|
) { git ->
|
||||||
pullBranchUseCase(git, pullType)
|
pullBranchUseCase(git, pullType)
|
||||||
}
|
}
|
||||||
@ -38,7 +40,7 @@ class MenuViewModel @Inject constructor(
|
|||||||
refreshEvenIfCrashes = true,
|
refreshEvenIfCrashes = true,
|
||||||
title = "Fetching",
|
title = "Fetching",
|
||||||
subtitle = "Updating references from the remote repositories...",
|
subtitle = "Updating references from the remote repositories...",
|
||||||
isCancellable = true
|
isCancellable = false
|
||||||
) { git ->
|
) { git ->
|
||||||
fetchAllBranchesUseCase(git)
|
fetchAllBranchesUseCase(git)
|
||||||
}
|
}
|
||||||
@ -48,7 +50,7 @@ class MenuViewModel @Inject constructor(
|
|||||||
refreshEvenIfCrashes = true,
|
refreshEvenIfCrashes = true,
|
||||||
title = "Push",
|
title = "Push",
|
||||||
subtitle = "Pushing current branch to the remote repository",
|
subtitle = "Pushing current branch to the remote repository",
|
||||||
isCancellable = true,
|
isCancellable = false,
|
||||||
) { git ->
|
) { git ->
|
||||||
pushBranchUseCase(git, force, pushTags)
|
pushBranchUseCase(git, force, pushTags)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user