Summary: | When `$(command -v kwrite)` is set as the value of `$Env:EDITOR`, `systemctl edit` generates an empty, useless tab alongside the expected one. | ||
---|---|---|---|
Product: | [Applications] kate | Reporter: | Roke Julian Lockhart Beedell <4wy78uwh> |
Component: | kwrite | Assignee: | KWrite Developers <kwrite-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | minor | CC: | oded |
Priority: | NOR | ||
Version First Reported In: | 24.12.3 | ||
Target Milestone: | --- | ||
Platform: | Fedora RPMs | ||
OS: | Linux | ||
URL: | https://discuss.kde.org/t/disable-kde-monitor-brightness-control/25134/13?u=rokejulianlockhart | ||
See Also: | https://github.com/microsoft/vscode/issues/243211#issue-2910882544 | ||
Latest Commit: | https://invent.kde.org/utilities/kate/-/commit/47ff616f309d392fcde7524eb5e70413f41f45d2 | Version Fixed In: | |
Sentry Crash Report: | |||
Attachments: | A Screenshot of KWrite `24.12.3-1.fc41.x86_64`'s Tabs for Comment 0. |
Description
Roke Julian Lockhart Beedell
2025-03-11 15:19:08 UTC
> comment #0 I forgot to add the damned most important part - the cause. As [`discuss.kde.org/t/25134/15`][1] states: > Yea, that a `systemctl` optimization for Nano that prepends `+{line-numer}` to the file name to get the > editor to start at the specified line. The Kate-ism for this is to postfix the line number to the filename > with a colon (i.e. `{filename}:{line-number}`), but my favorite terminal text editor - `mcedit` supports > both the `+` syntax and the `:` syntax, so maybe Kate can be convinced to also support both. [1]: https://discuss.kde.org/t/disable-kde-monitor-brightness-control/25134/15?u=rokejulianlockhart The presented file name being some kind of auto-generated temporary file (e.g. `.../.#override.conf13545878` or some such) is fine - this is `systemctl` generating a temporary file where it can add all the extra comments. Other editors also show the same behavior, and it is not a bug. The feature request here is for Kate/kwrite to support the CLI options "+{line-number} {filename}" to open {filename} at line {line-number}, in addition to the current support of "{filename}:{linenumber}", as it appears that some system tools use that syntax successfully with Nano and other command line editors. (In reply to Oded Arbel from comment #2) > The feature request here is for Kate/kwrite to support the CLI options "+{line-number} {filename}" to open {filename} at line {line-number}, in addition to the current support of "{filename}:{linenumber}", as it appears that some system tools use that syntax successfully with Nano and other command line editors. I'll probably have to refile this due to https://bugs.kde.org/show_bug.cgi?id=501354#c4, so I'll combine that with it when I do. A possibly relevant merge request was started @ https://invent.kde.org/utilities/kate/-/merge_requests/1753 Git commit 47ff616f309d392fcde7524eb5e70413f41f45d2 by Waqar Ahmed, on behalf of Christoph Cullmann. Committed on 17/03/2025 at 07:28. Pushed by waqar into branch 'master'. support +xyz line number as first argument CHANGELOG: Kate/KWrite supports 'kate +123 test.txt' to jump to the given line M +22 -7 apps/kate/main.cpp M +10 -8 apps/lib/kateapp.cpp M +23 -0 apps/lib/urlinfo.h https://invent.kde.org/utilities/kate/-/commit/47ff616f309d392fcde7524eb5e70413f41f45d2 (In reply to Waqar Ahmed from comment #5) Thank you! |