Vote #80959
完了Highlighted code with 'diff' format converts tabs to spaces, which breaks IDEs
0%
説明
If I paste some code like a @diff@ (patch format), then tabs are replaced by 4 spaces:
Index: web/SomeJs.js
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- web/SomeJs.js (revision a772b73079dfedeaafa2a941b33b4bb03fc77b2a)
+++ web/SomeJs.js (date 1593706024927)
@@ -7,13 +7,33 @@
};
SomeJs.prototype.isMobile = function () {
- return /Foo/.test("a");
Please compare with raw format, where I got some @Index: web/SomeJs.js IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- web/SomeJs.js(revision a772b73079dfedeaafa2a941b33b4bb03fc77b2a) +++ web/SomeJs.js (date 1593706024927) @@ -7,13 +7,33 @@ }; SomeJs.prototype.isMobile = function () { - return /Foo/.test("a");
This is annoying cause copying the @diff@ from the visual view does not work. I have to copy from the @Edit@ view and apply the patch in my IDE this way.
journals
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
I found that the same problem has already been reported as #28793. Closing this issue as a duplicate of it.
Thank you for reporting this issue.
--------------------------------------------------------------------------------
related_issues
duplicates,Confirmed,28793,Redmine replaces tabs with spaces in code blocks