-
Notifications
You must be signed in to change notification settings - Fork 11
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
Multiple file sources #149
Comments
#150 (comment) Different file sources may have utilities that are too specific for a generic |
I also recommend to move the git-specific code into its own submodule to pave the way to one day allow it (and its dependencies) to be turned off. |
Notes based on discussion in #174:
|
This changes the implementation of `Gengo` to take a generic `FileSource` type, moving git-specific stuff to its own module. This breaks usage by moving the `rev` argument from `Gengo::analyze` to `Builder::new` (there's a good chance that this will break again once other file sources are implemented). Closes #150 Resolves #165 Related to #149
Right now, the file source is a git repository via git2. But the analyzer is pretty flexible, and basically just needs to receive a filepath and bytes. So it might be cool to have a trait like
FileSource
, which would require an iterator method that returns a path and bytesand a static.open
methodBesides a git repository, another source could be the filesystem.
This could also perhaps lead to multiple binaries --
git-gengo
would analyze a git repository, andgengo
would analyze a directory.The text was updated successfully, but these errors were encountered: