Update a package: Difference between revisions

Flukx (talk | contribs)
Note for newer packages under /by-name
Likivik (talk | contribs)
m a link to discussion on how to adress big repo size (use blob instead of shallow)
 
(2 intermediate revisions by 2 users not shown)
Line 22: Line 22:
cd ~/devel/
cd ~/devel/
git clone https://github.com/your_username/nixpkgs.git \
git clone https://github.com/your_username/nixpkgs.git \
     --depth=1 # Prevents cloning the entire history, which is multiple gigabytes
     --filter=blob:none # Prevents downloading the entire history, which saves a couple Gb
cd nixpkgs/
cd nixpkgs/
git remote add upstream https://github.com/NixOS/nixpkgs.git</syntaxhighlight>
git remote add upstream https://github.com/NixOS/nixpkgs.git
git gc --aggressive # nixpkgs is a large repository; this brings down the disk usage by another Gb or so</syntaxhighlight>
* When the clone is not recent or you suspect there have been changes upstream (in official nixpkgs):
* When the clone is not recent or you suspect there have been changes upstream (in official nixpkgs):
<syntaxhighlight lang="bash">
<syntaxhighlight lang="bash">
Line 493: Line 494:
* [[Contributing#Contributing to the documentation|Contributing to Nix documentation]]
* [[Contributing#Contributing to the documentation|Contributing to Nix documentation]]
* [[Nixpkgs/Update Scripts]] - automatic updating of packages
* [[Nixpkgs/Update Scripts]] - automatic updating of packages
* [https://github.com/NixOS/nixpkgs/issues/423262 Offsetting huge nixpkgs repo size properly - discussion]


[[:Category:Tutorial]]
[[Category:Tutorial]]
[[:Category:Nixpkgs]]
[[Category:Nixpkgs]]
[[:Category:Contributing]]
[[Category:Contributing]]