{"id":19892908,"url":"https://github.com/cormacrelf/elk","last_synced_at":"2025-08-23T23:11:06.106Z","repository":{"id":242201615,"uuid":"808939731","full_name":"cormacrelf/elk","owner":"cormacrelf","description":"Generate BUCK build files from poetry dependencies","archived":false,"fork":false,"pushed_at":"2024-06-02T03:59:45.000Z","size":95,"stargazers_count":2,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-11T19:44:30.267Z","etag":null,"topics":["buck2","poetry-plugin","python"],"latest_commit_sha":null,"homepage":"","language":"Python","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/cormacrelf.png","metadata":{"files":{"readme":"README.md","changelog":null,"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}},"created_at":"2024-06-01T08:09:21.000Z","updated_at":"2024-11-09T03:25:40.000Z","dependencies_parsed_at":"2024-06-01T10:34:38.728Z","dependency_job_id":"319b4863-111a-4fb1-9a83-a7391dc4b11c","html_url":"https://github.com/cormacrelf/elk","commit_stats":null,"previous_names":["cormacrelf/elk"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cormacrelf%2Felk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cormacrelf%2Felk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cormacrelf%2Felk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cormacrelf%2Felk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cormacrelf","download_url":"https://codeload.github.com/cormacrelf/elk/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241321560,"owners_count":19943961,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["buck2","poetry-plugin","python"],"created_at":"2024-11-12T18:26:07.504Z","updated_at":"2025-03-01T05:26:11.988Z","avatar_url":"https://github.com/cormacrelf.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Elk\n\nGenerate [Buck](https://buck2.build) build files from Python + \n[Poetry](https://python-poetry.org) dependencies.\n\nMuch like [`reindeer`](https://github.com/facebookincubator/reindeer).\n\n\n### Status: experimental\n\nNot seriously tested on a big python codebase. But it does do toy examples.\nIt will probably break if there is more than one version of a particular \ndependency.\n\n### Install\n\n```sh\npipx install poetry\npipx inject poetry .\n```\n\n### Quick start\n\nJust follow along with the `example` folder. You'll probably want to copy the \n`elk.toml` and `platform.bzl` files.\n\n### Use buck2 to assemble the virtualenv for e.g. code completion\n\nSee `example/venv.sh`.\n\nConfigure `pyright` as usual, then:\n\n```sh\ncd example\n./venv.sh :main nvim main.py\n```\n\nYour editor will reflect the dependencies added in example/BUCK.\nSo if you edit the other target, you won't get access to the packages\n`cowsay` and `colorama`:\n\n```sh\n./venv.sh :other nvim other.py\n```\n\n### Using the poetry virtualenv for e.g. code completion\n\nPoetry still works, and you can just hook into that.\nConfigure `pyright` as usual, then:\n\n    cd example\n    poetry -C pypi run nvim\n\nOr otherwise use poetry to enter a shell with the virtualenv in it.\n\nIf you have a lot of python packages, and you've used `elk`\nto place all their dependencies in a single BUCK file, then you will\nget too many packages available in your language server, but Buck will\nstill precisely set up the paths when you `buck2 run`. Overall this might\nbe less annoying than getting the virtualenv path from buck.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcormacrelf%2Felk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcormacrelf%2Felk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcormacrelf%2Felk/lists"}