Loading a pattern file based on file extension? #1397
-
As the title suggests, is there a way to get a pattern to automatically load based on the extension of the file? I'm working with some raw serial port bytes I've dumped from an app I'm writing, and the file has no mime type, but will always have the same extension, so it'd be nice to be able to load the data with something like a Can this be done? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hey |
Beta Was this translation helpful? Give feedback.
Hey
This is generally not supported as file extensions don't really mean anything and not all providers even have the concept of file extensions.
Instead you can either write a custom magic file and assign a MIME type to your file that way or you use the new
#pragma magic [ AA ?? ?? DD ] @ 0x12345678
pragma.