Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

avro file type support added #597

Merged
merged 4 commits into from
May 10, 2023
Merged

avro file type support added #597

merged 4 commits into from
May 10, 2023

Conversation

IgorWiecz
Copy link
Contributor

Avro file type support added, steps in contributing.md file followed.

core.d.ts Outdated
@@ -167,6 +168,7 @@ export type MimeType =
| 'image/vnd.ms-photo'
| 'image/vnd.adobe.photoshop'
| 'application/x-indesign'
| 'application/avro'
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be added to the end.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

core.d.ts Outdated
@@ -2,6 +2,7 @@ import type {Readable as ReadableStream} from 'node:stream';
import type {ITokenizer} from 'strtok3';

export type FileExtension =
| 'avro'
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be added to the end.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

core.js Outdated
@@ -292,6 +299,13 @@ class FileTypeParser {
};
}

if (this.checkString('avro')) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you link to a source for this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see it written anywhere there that the file header must start with avro.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After further research I think you are correct, it is not specified anywhere that the file header MUST end with avro.
I have removed that check.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've also noticed people use .avsc and .acme, but I don't quite understand the difference

supported.js Outdated
@@ -1,4 +1,5 @@
export const extensions = [
'avro',
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was implied that #597 (comment) applied here too. And the below.

@sindresorhus sindresorhus merged commit 34ab7d4 into sindresorhus:main May 10, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants