{"id":49574512,"url":"https://github.com/dannote/zigler_precompiled","last_synced_at":"2026-05-03T16:01:51.801Z","repository":{"id":343937517,"uuid":"1179720065","full_name":"dannote/zigler_precompiled","owner":"dannote","description":"Download and use precompiled Zig NIFs safely with checksums","archived":false,"fork":false,"pushed_at":"2026-04-09T08:12:37.000Z","size":39,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-04-27T16:39:00.283Z","etag":null,"topics":["checksums","cross-platform","elixir","nif","precompiled","zig"],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dannote.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-12T10:05:53.000Z","updated_at":"2026-04-14T09:27:06.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/dannote/zigler_precompiled","commit_stats":null,"previous_names":["dannote/zigler_precompiled"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/dannote/zigler_precompiled","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dannote%2Fzigler_precompiled","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dannote%2Fzigler_precompiled/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dannote%2Fzigler_precompiled/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dannote%2Fzigler_precompiled/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dannote","download_url":"https://codeload.github.com/dannote/zigler_precompiled/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dannote%2Fzigler_precompiled/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32575115,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-03T06:36:36.687Z","status":"ssl_error","status_checked_at":"2026-05-03T06:36:09.306Z","response_time":103,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["checksums","cross-platform","elixir","nif","precompiled","zig"],"created_at":"2026-05-03T16:01:33.627Z","updated_at":"2026-05-03T16:01:51.795Z","avatar_url":"https://github.com/dannote.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ZiglerPrecompiled\n\nDownload and use precompiled [Zigler](https://github.com/E-xyza/zigler) NIFs\nsafely with SHA-256 checksums.\n\nRemoves the need for end users to install the Zig compiler. Library maintainers\nbuild NIFs in CI for each platform, upload them as release artifacts, and ship a\nchecksum file with the Hex package.\n\n## Installation\n\n```elixir\ndef deps do\n  [\n    {:zigler_precompiled, \"~\u003e 0.1.0\"}\n  ]\nend\n```\n\nFor library maintainers who also need to compile from source:\n\n```elixir\ndef deps do\n  [\n    {:zigler_precompiled, \"~\u003e 0.1.0\"},\n    {:zigler, \"~\u003e 0.15\", optional: true}\n  ]\nend\n```\n\n## Quick start\n\n### Defining a precompiled NIF module\n\n```elixir\ndefmodule MyApp.Native do\n  version = Mix.Project.config()[:version]\n\n  use ZiglerPrecompiled,\n    otp_app: :my_app,\n    base_url: \"https://github.com/me/my_project/releases/download/v#{version}\",\n    version: version,\n    nifs: [\n      add: 2,\n      multiply: 2\n    ]\nend\n```\n\nThe `:nifs` option is **required** — it declares which NIF functions the module\nexports as `{name, arity}` pairs. These generate stub functions that are\nreplaced when the precompiled `.so` loads.\n\nWhen `force_build: true` (or a pre-release version like `\"0.1.0-dev\"`), the\n`:nifs` option is ignored and compilation is delegated to `use Zig` with\nZigler's full wrapper generation.\n\n### Building and releasing\n\n1. Tag a release and push\n2. CI builds the NIF for each target and uploads `.tar.gz` artifacts\n3. Run `mix zigler_precompiled.download MyApp.Native --all --print`\n4. Include `checksum-*.exs` in your Hex package files\n5. Publish to Hex\n\nSee [PRECOMPILATION_GUIDE.md](PRECOMPILATION_GUIDE.md) for the full walkthrough.\n\n## How it works\n\nZigler generates rich NIF wrapper functions (type marshalling, error tracing)\nat compile time by analyzing Zig source. The compiled `.so` registers NIF\nfunctions under `marshalled-\u003cname\u003e` names. ZiglerPrecompiled generates matching\nstubs that delegate to these, so when `:erlang.load_nif` runs at `@on_load`,\nthe stubs are replaced with the real implementations.\n\nThis has been verified to work end-to-end with\n[QuickBEAM](https://github.com/dannote/quickbeam) (20 NIFs including resources,\ndirty schedulers, C interop with QuickJS and Lexbor).\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdannote%2Fzigler_precompiled","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdannote%2Fzigler_precompiled","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdannote%2Fzigler_precompiled/lists"}