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

Add support for Apple file list types for validation #68

Merged
merged 5 commits into from
Oct 20, 2023

Conversation

sandyydk
Copy link
Contributor

@sandyydk sandyydk commented Oct 14, 2023

Changes in this PR

  • Add validator for Plist file types
  • Test cases for Plist file type validation

Closes #66

@sandyydk
Copy link
Contributor Author

@kehoecj Tried to check plist files and did a basic validation similar to other ones for JSON etc. Let me know if this is fine.

@kehoecj kehoecj added OSS Community Contribution Contributions from the OSS Community hacktoberfest-accepted Valid PR Hacktoberfest PR hacktoberfest 🎃 Hacktoberfest 2024 labels Oct 14, 2023
@kehoecj kehoecj requested review from jd4235 and kehoecj October 16, 2023 22:01
pkg/validator/validator_test.go Outdated Show resolved Hide resolved
@kehoecj kehoecj requested a review from jackswiney October 17, 2023 13:22
@kehoecj
Copy link
Collaborator

kehoecj commented Oct 17, 2023

@sandyydk Please resolve merge conflicts from two PR's that have been merged

@sandyydk
Copy link
Contributor Author

sandyydk commented Oct 17, 2023 via email

index.md Outdated Show resolved Hide resolved
pkg/validator/valid.plist Outdated Show resolved Hide resolved
@sandyydk
Copy link
Contributor Author

sandyydk commented Oct 18, 2023 via email

@kehoecj
Copy link
Collaborator

kehoecj commented Oct 18, 2023

Sure. Will update the PR for the same. I was thinking if we should go with sub directories within validators to include these test files? If not will go with constant itself.

Would prefer constants for now

@kehoecj kehoecj merged commit 96f1b6a into Boeing:main Oct 20, 2023
Copy link
Contributor

@jd4235 jd4235 left a comment

Choose a reason for hiding this comment

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

Guess I failed to click the Submit review button. I thought the comment would still show up.

import (
"bytes"

"howett.net/plist"
Copy link
Contributor

Choose a reason for hiding this comment

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

https://pkg.go.dev/howett.net/plist#section-readme states four different plist formats are supported (Apple XML, Apple Binary, OpenStep and GNUStep). Looks like this only tests the XML variant. Are there plans to add support and tests for the other three?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Added a task to #60 to specify that only Apple XML is supported. I'll take a look into the other plist types and see how widely used they are and if they are worth supporting.

shiina4119 pushed a commit to shiina4119/config-file-validator that referenced this pull request Aug 23, 2024
* Add support for Apple file list types for validation

* Fix merge conflicts

* Move large strings from test cases to an embedded file

* Move large text in test case to a variable
shiina4119 pushed a commit to shiina4119/config-file-validator that referenced this pull request Oct 4, 2024
* Add support for Apple file list types for validation

* Fix merge conflicts

* Move large strings from test cases to an embedded file

* Move large text in test case to a variable
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hacktoberfest 🎃 Hacktoberfest 2024 hacktoberfest-accepted Valid PR Hacktoberfest PR OSS Community Contribution Contributions from the OSS Community
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add support for Apple Property List Files
3 participants