GNU bug report logs -
#70023
[PATCH] Add typescript-ts-mode indentation for interface bodies
Previous Next
Reported by: Noah Peart <noah.v.peart <at> gmail.com>
Date: Wed, 27 Mar 2024 06:21:02 UTC
Severity: normal
Tags: patch
Fixed in version 29.3
Done: Stefan Kangas <stefankangas <at> gmail.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 70023 in the body.
You can then email your comments to 70023 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#70023
; Package
emacs
.
(Wed, 27 Mar 2024 06:21:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Noah Peart <noah.v.peart <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Wed, 27 Mar 2024 06:21:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Tags: patch
Adds missing indentation for typescript interfaces.
Currently, there is no indentation for property signatures in typescript
interfaces.
To reproduce, call `M-x (my-test-typescript-indent)`
(defun my-test-typescript-indent ()
(interactive)
(typescript-ts-mode)
(setq-local typescript-ts-mode-indent-offset 4)
(indent-region (point-min) (point-max)))
in buffer with the following typescript code:
interface Foo {
foo: string; // no matching indent rule
bar?: boolean; // no matching indent rule
}
In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
3.24.33, cairo version 1.16.0) of 2024-03-24 built on noah-X580VD
Repository revision: c5de73a95a6ecefe46fe1ac07da8e83032be7f5b
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12101004
System Description: Ubuntu 22.04.4 LTS
Configured using:
'configure --prefix=/usr/local --with-modules --with-tree-sitter
--with-threads --with-x-toolkit=gtk3 --with-xwidgets --with-gnutls
--with-json --with-mailutils --with-jpeg --with-png --with-rsvg
--with-tiff --with-xml2 --with-xpm --with-imagemagick CC=gcc-12
CXX=gcc-12'
[Message part 2 (text/html, inline)]
[0001-Add-typescript-ts-mode-indentation-for-interface-bod.patch (text/x-patch, attachment)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#70023
; Package
emacs
.
(Thu, 28 Mar 2024 13:12:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 70023 <at> debbugs.gnu.org (full text, mbox):
Noah Peart <noah.v.peart <at> gmail.com> writes:
> Tags: patch
>
> Adds missing indentation for typescript interfaces.
>
> Currently, there is no indentation for property signatures in typescript
> interfaces.
>
> To reproduce, call `M-x (my-test-typescript-indent)`
>
> (defun my-test-typescript-indent ()
> (interactive)
> (typescript-ts-mode)
> (setq-local typescript-ts-mode-indent-offset 4)
> (indent-region (point-min) (point-max)))
>
> in buffer with the following typescript code:
>
> interface Foo {
> foo: string; // no matching indent rule
> bar?: boolean; // no matching indent rule
> }
Thanks - This looks good to me. Have you contributed to emacs earlier? I
think this could go in regardless as it is a trivial addition, or what,
Eli?
I'll install it on emacs-29 later today if noone cries out :-)
Theo
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#70023
; Package
emacs
.
(Thu, 28 Mar 2024 14:33:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 70023 <at> debbugs.gnu.org (full text, mbox):
> Cc: 70023 <at> debbugs.gnu.org
> Date: Thu, 28 Mar 2024 14:11:33 +0100
> From: Theodor Thornhill via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>
> Thanks - This looks good to me. Have you contributed to emacs earlier? I
> think this could go in regardless as it is a trivial addition, or what,
> Eli?
Noah has copyright assignment on file, so we can accept his
contributions without limitations.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#70023
; Package
emacs
.
(Thu, 28 Mar 2024 18:11:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 70023 <at> debbugs.gnu.org (full text, mbox):
Noah Peart <noah.v.peart <at> gmail.com> writes:
> Tags: patch
>
> Adds missing indentation for typescript interfaces.
>
> Currently, there is no indentation for property signatures in typescript
> interfaces.
>
> To reproduce, call `M-x (my-test-typescript-indent)`
>
> (defun my-test-typescript-indent ()
> (interactive)
> (typescript-ts-mode)
> (setq-local typescript-ts-mode-indent-offset 4)
> (indent-region (point-min) (point-max)))
>
[...]
Pushed in bcf6dd6e266222a293e359430afdf3a2dc18369c. I also added a test
confirming the behavior.
As a small aside, this node type was added very recently. Until now we
had a rule for it in 'object'
Thanks!
Theo
bug Marked as fixed in versions 29.3.
Request was from
Theodor Thornhill <theo <at> thornhill.no>
to
control <at> debbugs.gnu.org
.
(Thu, 28 Mar 2024 18:14:01 GMT)
Full text and
rfc822 format available.
Reply sent
to
Stefan Kangas <stefankangas <at> gmail.com>
:
You have taken responsibility.
(Sun, 30 Jun 2024 05:57:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Noah Peart <noah.v.peart <at> gmail.com>
:
bug acknowledged by developer.
(Sun, 30 Jun 2024 05:57:02 GMT)
Full text and
rfc822 format available.
Message #21 received at 70023-done <at> debbugs.gnu.org (full text, mbox):
Theodor Thornhill <theo <at> thornhill.no> writes:
> Noah Peart <noah.v.peart <at> gmail.com> writes:
>
>> Tags: patch
>>
>> Adds missing indentation for typescript interfaces.
>>
>> Currently, there is no indentation for property signatures in typescript
>> interfaces.
>>
>> To reproduce, call `M-x (my-test-typescript-indent)`
>>
>> (defun my-test-typescript-indent ()
>> (interactive)
>> (typescript-ts-mode)
>> (setq-local typescript-ts-mode-indent-offset 4)
>> (indent-region (point-min) (point-max)))
>>
>
> [...]
>
> Pushed in bcf6dd6e266222a293e359430afdf3a2dc18369c. I also added a test
> confirming the behavior.
>
> As a small aside, this node type was added very recently. Until now we
> had a rule for it in 'object'
I'm therefore closing this bug report.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sun, 28 Jul 2024 11:24:08 GMT)
Full text and
rfc822 format available.
This bug report was last modified 338 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.