{"id":15395150,"url":"https://github.com/orhun/alpkg","last_synced_at":"2025-04-16T00:05:10.933Z","repository":{"id":148032229,"uuid":"618848734","full_name":"orhun/alpkg","owner":"orhun","description":"Set up Alpine Linux packaging environment with a breeze! 🏔","archived":false,"fork":false,"pushed_at":"2023-12-14T12:58:05.000Z","size":9146,"stargazers_count":27,"open_issues_count":2,"forks_count":3,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-16T00:04:44.020Z","etag":null,"topics":["alpine","alpine-linux","alpine-package-builder","alpine-packaging","chroot","chroot-environment","packaging","packaging-scripts","packaging-tool"],"latest_commit_sha":null,"homepage":"https://blog.orhun.dev/alpine-packaging-setup/","language":"Shell","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/orhun.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":"orhun","patreon":"orhunp","custom":["https://www.buymeacoffee.com/orhun"]}},"created_at":"2023-03-25T14:32:02.000Z","updated_at":"2025-02-20T13:10:35.000Z","dependencies_parsed_at":"2024-02-09T09:31:30.997Z","dependency_job_id":"7fc763bf-d444-41e3-a156-192d0ef4a070","html_url":"https://github.com/orhun/alpkg","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orhun%2Falpkg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orhun%2Falpkg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orhun%2Falpkg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orhun%2Falpkg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/orhun","download_url":"https://codeload.github.com/orhun/alpkg/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249173084,"owners_count":21224483,"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":["alpine","alpine-linux","alpine-package-builder","alpine-packaging","chroot","chroot-environment","packaging","packaging-scripts","packaging-tool"],"created_at":"2024-10-01T15:26:12.047Z","updated_at":"2025-04-16T00:05:10.914Z","avatar_url":"https://github.com/orhun.png","language":"Shell","readme":"# `alpkg` 🏔\n\n[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/orhun/alpkg/ci.yml?logo=GitHub)](https://github.com/orhun/alpkg/actions)\n\n**Set up Alpine Linux packaging environment with a breeze!** See [**this blog post**](https://blog.orhun.dev/alpine-packaging-setup).\n\n![alpkg demo](assets/demo.gif)\n\n`alpkg` is a tool for _all_ your Alpine packaging needs. It can create a chroot with preinstalled tools in a matter of seconds, set up [aports repository](https://gitlab.alpinelinux.org/alpine/aports), and fetch/update packages. Most importantly, it provides a split layout via [Zellij](https://github.com/zellij-org/zellij) for easy editing/building [`APKBUILD`](https://wiki.alpinelinux.org/wiki/APKBUILD_Reference) files.\n\n## Requirements\n\n- [alpine-chroot-install](https://github.com/alpinelinux/alpine-chroot-install)\n  - See [requirements](https://github.com/alpinelinux/alpine-chroot-install#requirements).\n\n## Usage\n\n```\nUsage: alpkg [init|edit|fetch|update] [\u003cpackage\u003e]\n\nCommands:\n  init              Initialize an Alpine chroot.\n  edit \u003cpackage\u003e    Edit or create a package.\n  fetch \u003cpackage\u003e   Fetch an existing package from the remote repository.\n  update \u003cpackage\u003e  Update the package on the remote repository.\n  destroy           Remove the chroot and repository.\n\nOptions:\n  --packager \"Your Name \u003cyour@email.address\u003e\"              The name and email address of the package maintainer.\n  --aports \"https://gitlab.alpinelinux.org/\u003cuser\u003e/aports\"  The URL of the remote APorts repository.\n\nEnvironment variables:\n  CHROOT_DIR   Directory for Alpine chroot. (default: /alpine)\n  APORTS_DIR   Directory for remote APorts repository. (default: /home/user/aports)\n  PACKAGE_DIR  Directory for APK packages built and stored. (default: /home/user/apkbuilds in chroot)\n```\n\n## Features\n\n### `init`\n\nTo create an Alpine Linux chroot and initialize [aports repository](https://gitlab.alpinelinux.org/alpine/aports) for packaging, simply run:\n\n```sh\nalpkg init --packager \"Your Name \u003cyour@email.address\u003e\" --aports \"https://gitlab.alpinelinux.org/\u003cuser\u003e/aports\"\n```\n\nIt is possible to pass options to `alpine-chroot-install` via environment variables.\n\n\u003cdetails\u003e\n\u003csummary\u003eDemo\u003c/summary\u003e\n\n![alpkg init](assets/init.gif)\n\n\u003c/details\u003e\n\n\\* You need to create an account on [https://gitlab.alpinelinux.org](https://gitlab.alpinelinux.org) and fork the [aports repository](https://gitlab.alpinelinux.org/alpine/aports) under your user.\n\n\\* If you run `alpkg init` in your `$HOME` directory, the Alpine working directory will point to `$HOME/apkbuilds`.\n\n### `edit`\n\nTo create a new `APKBUILD`, you can use the `edit` command. Note that it uses [`newapkbuild`](https://wiki.alpinelinux.org/wiki/Include:Newapkbuild) under the hood so you can pass `newapkbuild` options to it:\n\n```sh\nalpkg edit \u003cnewapkbuild_opts\u003e \u003cpackage_name\u003e\n```\n\nFor example:\n\n```sh\nalpkg edit -r -d \"A highly customizable changelog generator\" -l \"GPL-3.0-only\" -u \"https://github.com/orhun/git-cliff\" git-cliff\n```\n\nOr you can generate an empty package with the following command:\n\n```sh\nalpkg edit testpkg\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eDemo\u003c/summary\u003e\n\n![alpkg edit I](assets/edit-1.gif)\n\n\u003c/details\u003e\n\nIf the package _already exists_, you can also use `edit` command to edit the contents of the `APKBUILD`.\n\n\u003cdetails\u003e\n\u003csummary\u003eDemo\u003c/summary\u003e\n\n![alpkg edit II](assets/edit-2.gif)\n\n\u003c/details\u003e\n\n### `fetch`\n\nTo fetch existing packages from `aports` and edit them:\n\n```sh\nalpkg fetch \u003cpackage_name\u003e\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eDemo\u003c/summary\u003e\n\n![alpkg fetch](assets/fetch.gif)\n\n\u003c/details\u003e\n\n### `update`\n\nTo commit the changes to the `aports` repository:\n\n```sh\nalpkg update \u003cpackage_name\u003e\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eDemo\u003c/summary\u003e\n\n![alpkg update](assets/update.gif)\n\n\u003c/details\u003e\n\n## License\n\nThis project is licensed under [The MIT License](./LICENSE).\n\n## Copyright\n\nCopyright © 2023, [Orhun Parmaksız](mailto:orhunparmaksiz@gmail.com)\n","funding_links":["https://github.com/sponsors/orhun","https://patreon.com/orhunp","https://www.buymeacoffee.com/orhun"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Forhun%2Falpkg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Forhun%2Falpkg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Forhun%2Falpkg/lists"}