-
Notifications
You must be signed in to change notification settings - Fork 5
Description
Hi there,
First of all, I want to thank you for contributing to hexdocs_docset_api. It's been really cool checking in and seeing what you've done while I've been doing other things. In preparation for potentially working on an Elixir project in the near future, I thought I'd take a look at how this project runs in 2024.
I found that there's a few barriers to getting things smoothly again, some of which I've already addressed in my "upgrades" branch which you can check out here: https://github.com/johnhamelink/hexdocs_docset_api/tree/upgrade
Done so far:
- The Mix task example was a bit brittle, for example it did not support relative URLs. I've fixed that now.
- When running in Mix Task mode, any bug while looping through dependencies would stop the rest of the process.
- For me, the Builder was using the destination directory as a working space, thereby polluting the destination directory. I've ensured the destination space is entirely decoupled from the scratch/workspace.
- The builder logic had the idea of a destination path, but it was confusing to use and the state struct had enough data to reconstruct the URL anyway, so I removed it.
- I introduced an extra archival step which is distinct from the build step. Not only does this follow idioms in other CI/CD software, it also further simplifies the logic
- I added a Nix flake with a minimal dev environment, and hooked it up to the
default.nixpackage, so that a flake user can also runnix build, and all of the things that go along with that. - I added a method for detecting which version of ExDoc is being used. This is then used to handle special fixes for versions with breaking changes.
WIP:
- Go through the entire logic and clean it up - I've done a bit of this already, but more is needed and I didn't even look through it all yet!
- I am going to write some tests for this project as well, which I'm sure will help in lowering the complexity.
- Successfully indexed:
- Behaviour (currently stored as an Interface in order to maintain compatibility with the spec)
- Function
- Type
- Module
- Guide
- Exception
- Protocol
- Callback
- Macro
- The contents of the docsets themselves are not very good right now. I need to investigate what's changed. Tested with:
- ExDoc 0.34.x
- ExDoc 0.28.x
- ExDoc 0.25.x
- ExDoc 0.23.x
TODOs:
- Phoenix 1.7 isn't supported yet - there were incompatible API changes made in that major revision that need to be addressed. I want to add support for 1.7.
- There's a bug where codeblocks show up all on one line for some reason. Need to investigate that.
- It seems like exqlite-0.7.0 is failing to build in Nixpkgs. I'll need to investigate that and get the package building properly.
- Perhaps if I get round to it, I'll host a server for people to connect to and use, just like http://.kapeli.com.
- Add support for other documentation systems such as EDoc (which is what Hackney uses: https://hexdocs.pm/hackney/)
I'd love to hear your thoughts on what I'm doing. My plan for now is to do this all in one upgrade branch, and then to submit it to this repo as a pull request. If you'd prefer that I resume maintaining the project I'm open to that as well.
All the best,
JH
