mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
cleanup
GitOrigin-RevId: 034169c14d41e0c736e7bc7e133718b084c149ff
This commit is contained in:
committed by
intellij-monorepo-bot
parent
14541e62d8
commit
1a476dd114
@@ -23,7 +23,7 @@ class MyPrettyPrinter : DefaultPrettyPrinter() {
|
||||
_arrayIndenter = NopIndenter.instance
|
||||
}
|
||||
|
||||
override fun createInstance(): MyPrettyPrinter = MyPrettyPrinter()
|
||||
override fun createInstance() = MyPrettyPrinter()
|
||||
|
||||
override fun writeObjectFieldValueSeparator(jg: JsonGenerator) {
|
||||
jg.writeRaw(": ")
|
||||
@@ -86,17 +86,12 @@ class ReadonlySource(var url: String? = null, var active: Boolean = true) {
|
||||
val path: String?
|
||||
@JsonIgnore
|
||||
get() {
|
||||
if (url == null) {
|
||||
return null
|
||||
}
|
||||
else {
|
||||
var fileName = PathUtilRt.getFileName(url!!)
|
||||
val suffix = ".git"
|
||||
if (fileName.endsWith(suffix)) {
|
||||
fileName = fileName.substring(0, fileName.length - suffix.length)
|
||||
}
|
||||
// the convention is that the .git extension should be used for bare repositories
|
||||
return "${sanitizeFileName(fileName)}.${Integer.toHexString(url!!.hashCode())}.git"
|
||||
var fileName = PathUtilRt.getFileName(url ?: return null)
|
||||
val suffix = ".git"
|
||||
if (fileName.endsWith(suffix)) {
|
||||
fileName = fileName.substring(0, fileName.length - suffix.length)
|
||||
}
|
||||
// the convention is that the .git extension should be used for bare repositories
|
||||
return "${sanitizeFileName(fileName)}.${Integer.toHexString(url!!.hashCode())}.git"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user