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

Improvements + removal of go anti-patterns #147

Open
Mzack9999 opened this issue Oct 10, 2023 · 0 comments
Open

Improvements + removal of go anti-patterns #147

Mzack9999 opened this issue Oct 10, 2023 · 0 comments
Assignees
Labels
Type: Maintenance Updating phrasing or wording to make things clearer or removing ambiguity.

Comments

@Mzack9999
Copy link
Member

Mzack9999 commented Oct 10, 2023

  • The type StringSlice should be vaporized and revert back to []string - the reference implementation should accept as destination var the basic []string go type, just like in https://github.com/spf13/cobra (ref https://pkg.go.dev/github.com/spf13/pflag?utm_source=godoc#pkg-index). Normalization options should be pluggable variadic arguments (eg. WithLowerCase(..), WithUpperCase(..), etc), it's up to the caller to set the wanted options.
  • Only a very limited subset should be kept, such as FileToStringSlice which supports automatically reading from file
  • All the implicit normalization (spaces, "' in comma separated strings) implicit logic must be removed and handled with only caller defined options (this is the source of intinite issues with various XXXTypeHolder wrappers in nuclei codebase)
@Mzack9999 Mzack9999 added the Type: Maintenance Updating phrasing or wording to make things clearer or removing ambiguity. label Oct 10, 2023
@Mzack9999 Mzack9999 self-assigned this Oct 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Maintenance Updating phrasing or wording to make things clearer or removing ambiguity.
Projects
None yet
Development

No branches or pull requests

1 participant