draft about how to upstream packages into nixos

This commit is contained in:
colin 2022-07-10 02:15:36 -07:00
parent ec2287562e
commit 14df37d353
1 changed files with 21 additions and 0 deletions

View File

@ -0,0 +1,21 @@
+++
title = "Template Blog Entry"
description = "remove DRAFT prefix and add a date field to link this from the index and feeds"
+++
first, i create a package in `~/nixos/pkgs/my-package`, add it to the `~/nixos/pkgs/overlay.nix`, and rebuild.
after i know the package is working reliably i:
- add the package to `~/dev/nixpkgs`
- `git diff HEAD~1.. > ~/nixos/nixpatches/my-package.patch`
- link this `my-package.patch` into the nixpatches and remove `~/nixos/pkgs/my-package`.
after my overlay is working reliably i:
- `git push colinsane new-pkg-my-package` and open a PR.
as the PR is worked, i'll repeat this process (`git diff` into a patch, then commit & push once i see it's working).
once the PR is merged i:
- replace `~/nixos/nixpatches/my-package.patch` with a link to the PR's diff instead.
finally as new nixos versions are released my `~/nixos/nixpatches` directory shrinks.