sqids/sqids-zig

Release first version

Closed this issue ยท 8 comments

4kimov commented

Referencing sqids/sqids-spec#14

Todos:

Main points to address before 0.1.0 are:

  • the initialization of the alphabet and blocklist: right now it is processed at each call to sqids.encode not anymore
  • default blocklist
  • alphabet validation: length and characters
  • full test suite

I'll create dedicated issue to track them if it lingers for a while

4kimov commented

Nice, I commented on encode params here.

Regarding the blocklist, feel free to hardcode it from here: https://raw.githubusercontent.com/sqids/sqids-blocklist/main/output/blocklist.json

@4kimov test suite is complete ๐Ÿ˜€

4kimov commented

@lvignoli Nice, thanks for letting me know & the test suite!

A few questions for you:

  1. Did I get examples right? Is it safe to omit defer for simplicity?
  2. Am I using constructor opts correctly in those examples? I noticed the readme passes those opts to encode (at the bottom of the doc)
  3. Do you know if it's possible to setup Github Actions for this repo?
  1. It is clearer to remove the allocator.free() calls from examples, docs (and Zig paradigm) seems sufficient.
  2. Yes your usage is correct, I forgot to update, will fix asap!
  3. That's the next step indeed, to automate linting and release. Zig is not 1.0 though, so every minor release may break the action, but that's expected.
4kimov commented

Great, thank you for clarifying everything. I'll close this issue since the first version is done! Thank you for the work ๐Ÿ’ช

I'll tag a v0.1 bound to work with a recent Zig version, and setup actions after Christmas ๐ŸŽ„
Thank you for your nice feedback, it was a pleasure to contribute ๐Ÿ˜Š

4kimov commented

Thank you, same ๐ŸŽ„๐Ÿ˜Š