Skip to content

Commit c10d26a

Browse files
committed
Clean up GitClient.kt
Add clarifying newlines.
1 parent fadbe8a commit c10d26a

File tree

1 file changed

+5
-0
lines changed
  • affectedmoduledetector/src/main/kotlin/com/dropbox/affectedmoduledetector

1 file changed

+5
-0
lines changed

affectedmoduledetector/src/main/kotlin/com/dropbox/affectedmoduledetector/GitClient.kt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ interface GitClient {
3030
top: Sha = "HEAD",
3131
includeUncommitted: Boolean = false
3232
): List<String>
33+
3334
fun getGitRoot(): File
3435

3536
/**
@@ -40,10 +41,12 @@ interface GitClient {
4041
* Executes the given shell command and returns the stdout as a string.
4142
*/
4243
fun execute(command: String): String
44+
4345
/**
4446
* Executes the given shell command and returns the stdout by lines.
4547
*/
4648
fun executeAndParse(command: String): List<String>
49+
4750
/**
4851
* Executes the given shell command and returns the first stdout line.
4952
*/
@@ -97,6 +100,7 @@ internal class GitClientImpl(
97100
}
98101
return null
99102
}
103+
100104
@Suppress("LongParameterList")
101105
private fun parseCommitLogString(
102106
commitLogString: String,
@@ -162,6 +166,7 @@ internal class GitClientImpl(
162166
check(proc.exitValue() == 0) { "Nonzero exit value running git command." }
163167
return stdout
164168
}
169+
165170
override fun executeAndParse(command: String): List<String> {
166171
val response = execute(command)
167172
.split(System.lineSeparator())

0 commit comments

Comments
 (0)