mojoa
April 24, 2019, 9:14pm
1
Is there a way to comment out sections of a config.toml file?
The config.toml file I am working with uses a #
symbol on each line to remark that line.
# facebook = "#"
# twitter = "#"
# dribbble = "#"
Is there a way to remark a block by placing characters before and after the block?
Example for c /*comment*/ for python '''comment '''
zwbetz
April 24, 2019, 9:16pm
2
Which text editor do you use? In vscode for example, I can select multiple lines then press control + / to comment/uncomment them
1 Like
mojoa
April 24, 2019, 9:24pm
3
Its Gedit on Fedora and it seems to “understand” toml.
Sometimes I may use vi from the command line though.
The toml spec says it is like this:
# This is a full-line comment
key = "value" # This is a comment at the end of a line
… so the editor would need to understand that for toml, and just comment each line as appropriate for a language like toml.
Did you try installing gedit-plugins, enabling “Code Comment” and then using ctrl-m and shift-ctrl-m to toggle?
1 Like
mojoa
April 24, 2019, 11:06pm
5
Gedit does highlight and understand TOML, however I do not see an option for enabling “Code Comment”
If the Toml Spec does not show the block code comment capability, that actually answers my question.
Thanks!
Sometimes IT moves backwards
zwbetz
April 24, 2019, 11:36pm
6
Bulk comments were proposed in the past but were deemed “not minimal syntax”
1 Like
mojoa
April 25, 2019, 12:28am
7
Well, by that logic they should have eliminated commenting all together.
Block Comments and their recognised usefulness have been around for a very long time.
http://www.gavilan.edu/csis/languages/comments.html
jmooring
Split this topic
November 21, 2022, 5:28am
8