summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2021-11-03 20:36:13 +0100
committerDavid Faure <faure@kde.org>2021-12-12 19:20:01 +0000
commit3a1162227ddae817aa3fdc71129790f345fc1140 (patch)
tree45c9aff84a5fa08186dfce7849bb42cb45e05cb5
parent8feb299b037c48a1a67697ba868ccc939a851ba0 (diff)
downloadshared-mime-info-3a1162227ddae817aa3fdc71129790f345fc1140.tar.gz
Add FlashForge "xgcode" mime-type
FlashForge's FlashPrint software uses gcode with a binary header containing extra data to save sliced models. Seeing as they have a known magic and that we might want to use them outside of FlashPrint itself, add a mime-type.
-rw-r--r--data/freedesktop.org.xml.in8
-rw-r--r--tests/mime-detection/20mm_Box.gxbin0 -> 130031 bytes
-rw-r--r--tests/mime-detection/list1
3 files changed, 9 insertions, 0 deletions
diff --git a/data/freedesktop.org.xml.in b/data/freedesktop.org.xml.in
index 399e7e7f..ee392fa0 100644
--- a/data/freedesktop.org.xml.in
+++ b/data/freedesktop.org.xml.in
@@ -7644,6 +7644,14 @@ command to generate the output files.
<glob pattern="*.gcode"/>
</mime-type>
+ <mime-type type="text/x-gcode-gx">
+ <comment>G-code Extended file</comment>
+ <magic>
+ <match type="string" value="xgcode 1.0" offset="0"/>
+ </magic>
+ <glob pattern="*.gx"/>
+ </mime-type>
+
<mime-type type="application/x-fds-disk">
<comment>Nintendo FDS disk image</comment>
<acronym>FDS</acronym>
diff --git a/tests/mime-detection/20mm_Box.gx b/tests/mime-detection/20mm_Box.gx
new file mode 100644
index 00000000..ea77861e
--- /dev/null
+++ b/tests/mime-detection/20mm_Box.gx
Binary files differ
diff --git a/tests/mime-detection/list b/tests/mime-detection/list
index 946a0575..07eb9774 100644
--- a/tests/mime-detection/list
+++ b/tests/mime-detection/list
@@ -840,6 +840,7 @@ dbus-comment.service text/x-dbus-service
binary.stl model/stl oxo
ascii.stl model/stl
test.gcode text/x.gcode ox
+20mm_Box.gx text/x-gcode-gx
# Virtualization disk images
disk.qcow2 application/x-qemu-disk