-
Notifications
You must be signed in to change notification settings - Fork 14
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
Detect unsupported tools in projects #237
Conversation
scanner/unknown.go
Outdated
ProjectTree string | ||
} | ||
|
||
var UnknownToolDetectors = []UnknownToolDetector{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bazel is missing from the list.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed!
scanner/unknown.go
Outdated
"Framework", | ||
} | ||
|
||
type singleFileToolDetector struct { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The singleFileToolDetector
and multiFileToolDetector
implementations are too similar to each other which made me think we could unify them. Like a singleFileToolDetector
can be represented with a multiFileToolDetector
with a single required item and an empty optional items list.
And if we do that then we can drop the first part of its name and just keep toolDetector
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a good idea actually!
scanner/unknown.go
Outdated
"Pods", | ||
"Carthage", | ||
"CordovaLib", | ||
"Framework", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tothszabi is this the correct folder name for iOS frameworks? I couldn't find any good info about this one folder name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good that you asked this question because I have missed this. At the moment we use .framework
and I think we should use that instead of Framework
.
bitrise-init/vendor/github.com/bitrise-io/go-xcode/pathfilters/pathfilters.go
Line 19 in d213de3
frameworkExt = ".framework" |
Have look if you could reuse these existing filters.
Context
Detect unsupported tools/frameworks/platforms in the project directory to log them later.
Changes
scanner/unknown.go
for everything related to scanning the repo for unsupported but recognized tools. This is not a scanner though, because it needs to run only after all other platform scanners fail.singleFileToolDetector
that looks for only a single file namemultiFileToolDetector
that first looks for a primary file name, but can also find one of the optional files as a fallbackkotlinMultiplatformDetector
because there is no distinct file name pattern for KMM, so it also looks at the file contents of certain files 🤷tree
command, but a bit simpler.Decisions
Out of scope for this PR