After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 764032 - .TOML syntax file
.TOML syntax file
Status: RESOLVED FIXED
Product: gtksourceview
Classification: Platform
Component: Syntax files
unspecified
Other Linux
: Normal normal
: ---
Assigned To: GTK Sourceview maintainers
GTK Sourceview maintainers
Depends on:
Blocks:
 
 
Reported: 2016-03-22 15:19 UTC by Alexander Schlarb
Modified: 2018-03-10 11:00 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
TOML syntax highlighting file (6.17 KB, application/xml)
2016-03-22 15:19 UTC, Alexander Schlarb
  Details
toml.lang: Add new definition for toml files (9.58 KB, patch)
2018-03-04 17:08 UTC, Tobias Schönberg
none Details | Review
toml.lang: Add new definition for toml files (11.63 KB, patch)
2018-03-04 17:55 UTC, Tobias Schönberg
none Details | Review
toml.lang: Add new definition for toml files (11.60 KB, patch)
2018-03-05 19:34 UTC, Tobias Schönberg
none Details | Review
toml.lang: Add new definition for toml files (11.60 KB, patch)
2018-03-06 20:56 UTC, Tobias Schönberg
committed Details | Review

Description Alexander Schlarb 2016-03-22 15:19:06 UTC
Created attachment 324543 [details]
TOML syntax highlighting file

Syntax file for the TOML configuration language (used by rust's cargo and others). It's inspired by INI by more well-defined and allows for arbitrary-depth lists.

File copied from here: https://github.com/fcharlie/toml.lang

Has copyrights and an elaborate example file that is displayed correctly.

Please merge this!
Comment 1 Tobias Schönberg 2018-03-04 17:08:29 UTC
Created attachment 369274 [details] [review]
toml.lang: Add new definition for toml files

Changes to be committed:
	modified:   data/language-specs/Makefile.am
	new file:   data/language-specs/toml.lang
	modified:   po/POTFILES.skip
	new file:   tests/syntax-highlighting/file.toml
Comment 2 Tobias Schönberg 2018-03-04 17:10:07 UTC
Permission was given by the author here: https://github.com/liv-dumea/toml.lang/issues/1
Comment 3 Tobias Schönberg 2018-03-04 17:55:40 UTC
Created attachment 369275 [details] [review]
toml.lang: Add new definition for toml files

Changes to be committed:
	modified:   data/language-specs/Makefile.am
	new file:   data/language-specs/toml.lang
	modified:   po/POTFILES.skip
	new file:   tests/syntax-highlighting/file.toml
Comment 4 Sébastien Wilmet 2018-03-05 19:12:17 UTC
Review of attachment 369275 [details] [review]:

Thanks, some minor problems.

::: data/language-specs/toml.lang
@@ +21,3 @@
+-->
+
+<language id="toml" _name="TOML" version="2.0" _section="Others">

_name -> name.

@@ +37,3 @@
+    <style id="boolean-value" _name="Boolean value" map-to="def:boolean"/>
+    <style id="datetime-value" _name="Datetime value" map-to="def:constant"/>
+    <style id="error"         _name="Error"                 map-to="def:error"/>

The same for styles.
Comment 5 Tobias Schönberg 2018-03-05 19:34:24 UTC
Created attachment 369363 [details] [review]
toml.lang: Add new definition for toml files

Changes to be committed:
	modified:   data/language-specs/Makefile.am
	new file:   data/language-specs/toml.lang
	modified:   po/POTFILES.skip
	new file:   tests/syntax-highlighting/file.toml
Comment 6 Sébastien Wilmet 2018-03-06 10:02:59 UTC
Review of attachment 369363 [details] [review]:

.

::: data/language-specs/toml.lang
@@ +21,3 @@
+-->
+
+<language id="toml" name="TOML" version="2.0" _section="Others">

The _section must be "Other", not "Others" (the sections have been renamed several years ago).
Comment 7 Tobias Schönberg 2018-03-06 20:56:31 UTC
Created attachment 369391 [details] [review]
toml.lang: Add new definition for toml files

Changes to be committed:
	modified:   data/language-specs/Makefile.am
	new file:   data/language-specs/toml.lang
	modified:   po/POTFILES.skip
	new file:   tests/syntax-highlighting/file.toml
Comment 8 Sébastien Wilmet 2018-03-07 10:28:26 UTC
Review of attachment 369391 [details] [review]:

Looks good, thanks. But it's currently the hard code freeze, so it'll need to wait next week to merge the patch.
Comment 9 Tobias Schönberg 2018-03-07 16:32:02 UTC
Thanks for the review. Looking for forward to our improved Rust support :)
Comment 10 Sébastien Wilmet 2018-03-10 10:58:40 UTC
Attachment 369391 [details] pushed as 4e4a9c5 - toml.lang: Add new definition for toml files
Comment 11 Sébastien Wilmet 2018-03-10 11:00:05 UTC
The *.lang files will be synchronized to GSV 3 soon.