1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-17 19:21:04 +00:00
nixpkgs/pkgs/by-name
2024-09-11 08:11:13 -04:00
..
_0/_0xpropo
_1/_1fps
_2/_2ship2harkinian
_4
_6/_64gram
_9/_9base
a4/a4
a5/a52dec
aa
ab
ac
ad ad-miner: 1.5.2 -> 1.6.0 2024-09-10 20:47:47 +00:00
ae
af
ag
ai aider-chat: 0.54.0 -> 0.56.0 2024-09-10 15:39:55 +02:00
al
am
an
ao/aocl-utils
ap
aq/aquamarine
ar
as astartectl: 23.5.2 -> 24.5.0 2024-09-10 09:53:03 +00:00
at
au
av
aw
ax
ay
az
b3/b3sum
ba basedpyright: 1.17.2 -> 1.17.3 2024-09-10 03:36:32 +00:00
bc
bd
be bevelbar: 24.06 -> 24.07 (#337670) 2024-09-10 00:55:16 +02:00
bi
bk/bk
bl
bm
bn/bngblaster
bo boogie: 3.2.3 -> 3.2.4 (#335316) 2024-09-09 22:52:39 +02:00
bp
bq/bqn
br
bs
bt
bu
by
c-
c2
ca cameractrls: 0.6.6 -> 0.6.7 (#340933) 2024-09-10 16:37:48 +08:00
cb
cc
cd
ce
cf/cf-tool
cg
ch chawan: 0-unstable-2024-08-03 -> 0-unstable-2024-09-03 (#336480) 2024-09-09 22:18:06 +02:00
ci
cj/cjs
cl clash-verge-rev: add meta for internal package (#340771) 2024-09-10 16:14:41 +08:00
cm
cn
co code-cursor: init at 0.40.4 (#337331) 2024-09-10 16:31:37 +08:00
cp
cq/cq
cr
cs
ct/ctx
cu
cv/cvemap
cw/cwe-client-cli
cy
cz/czkawka
da
db
dc
dd
de devenv: fix build on darwin 2024-09-11 08:37:45 +01:00
dg/dgoss
dh/dhcpig
di discover-overlay: 0.7.4 -> 0.7.8 (#335033) 2024-09-09 23:57:38 +02:00
dj/djent
dm
dn
do dotenvx: 1.8.0 -> 1.14.0 (#337739) 2024-09-10 10:35:00 +09:00
dp
dr
ds
dt
du
dv/dvb-apps
dw
dx
dy
e1/e1s
ea
eb
ec
ed
ee/eepers
ef/efibootmgr
eg/eg25-manager
ei
ej/ejsonkms
ek
el
em
en
eo/eog
ep
er
es
et
eu
ev
ew/eww
ex
ey/eyewitness
ez/eza
f2/f2fs-tools
fa fastcdr: 2.2.3 -> 2.2.4 2024-09-10 12:53:51 +00:00
fb/fbset
fc
fe
ff
fg/fgqcanvas
fi firefly-iii-data-importer: 1.5.4 -> 1.5.5 (#339864) 2024-09-10 20:29:22 +03:00
fj/fjo
fl flameshot: 12.1.0-unstable-2024-08-02 -> 12.1.0-unstable-2024-09-01 (#339506) 2024-09-11 00:47:45 +02:00
fm
fn/fnott
fo
fr
fs
ft/fte
fu
fv
fw/fwupd
fx/fx
fy
fz
g3/g3kb-switch
ga
gb
gc
gd
ge
gf
gg/gg
gh gh-markdown-preview: 1.7.0 -> 1.8.0 2024-09-10 12:59:47 +00:00
gi Merge: gitea: 1.22.1 -> 1.22.2 (#339891) 2024-09-10 17:58:49 +02:00
gk/gk-cli
gl
gm
gn
go gopls: 0.16.1 -> 0.16.2 (#341037) 2024-09-11 08:11:13 -04:00
gp
gr
gt
gu
gv/gvisor
gx/gxml
h2/h2
h5/h5utils
h8/h8mail
ha
hb/hb-honeypot
hc/hclfmt
hd
he
hi
hj/hjson-go
hn/hn-text
ho home-manager: 0-unstable-2024-08-23 -> 0-unstable-2024-09-09 2024-09-09 20:03:44 +00:00
hp
ht
hu
hv/hvm
hw/hwinfo
hx/hxtools
hy hydra: improve structuredAttrs support (#340840) 2024-09-10 00:06:09 +03:00
i2/i2p
i3
ia
ic
id
if
ig igir: 2.9.2 -> 2.11.0 (#329391) 2024-09-09 23:11:12 +02:00
ii
ij
im
in
io
ip
ir
is
it
iu/iucode-tool
iv
iw/iw
iz/izrss
ja
jc/jcli
jd/jdt-language-server
je
ji
jj/jj
jn
jo
jq/jq-zsh-plugin
jr
js
jt/jtdx
ju
jw/jwasm
k8/k8s-manifest-sigstore
ka
kc
kd
ke
kg/kgeotag
ki kitex: 0.10.3 -> 0.11.0 2024-09-09 17:25:58 +00:00
kl
km
kn
ko kokkos: 4.3.01 -> 4.4.00 (#335928) 2024-09-09 22:39:45 +02:00
kp/kplex
kr
ks
kt
ku
kv/kvmarwaita
kx
ky
la
lb
lc
ld
le lefthook: 1.7.14 -> 1.7.15 2024-09-09 19:26:26 +00:00
lg/lgogdownloader
li libbase58: init at 0.1.4 (#340834) 2024-09-11 01:24:37 +02:00
lk/lk-jwt-service
ll
lm
ln/lngen
lo
lp
lr/lrcget
ls
lt/ltris
lu
lv/lv_font_conv
lw/lwgrp
lx
lz
m1/m1ddc
m2
ma marwaita-mint: 20.3.1 -> 21 2024-09-10 08:19:25 +00:00
mb
mc
md
me melonDS: 0.9.5-unstable-2024-08-21 -> 0.9.5-unstable-2024-09-06 (#340730) 2024-09-10 12:12:13 +00:00
mf
mg
mi microcode-intel: 20240813 -> 20240910 2024-09-10 21:21:46 +02:00
mk
ml/mlx42
mo mouse-actions-gui: 0.4.4 -> 0.4.5 (#340844) 2024-09-10 20:32:54 +03:00
mp mpris-notifier: 0.1.7 -> 0.1.9 2024-09-10 01:17:16 +00:00
mq
mr/mricron
ms
mu
my
n2/n2
n8/n8n n8n: drop myself from maintainers 2024-09-11 12:58:24 +03:00
n9/n98-magerun2
na
nb
nc
nd/ndstrim
ne
nf
ng
nh
ni nitrokey-fido2-firmware: init at 2.4.1 (#337951) 2024-09-10 16:21:18 +02:00
nl
nm
nn nncp: 8.10.0 -> 8.11.0 2024-09-09 18:13:56 +00:00
no
np
nr
ns
nt
nu
nv
nw
nx/nxengine-evo
nz
oa
ob
oc
od
oe/oelint-adv
of
oh oh-my-posh: 23.4.0 -> 23.12.0 2024-09-10 12:45:41 +00:00
oi
ok
ol
om omekasy: 1.2.3 -> 1.3.1 2024-09-09 14:37:23 +00:00
on
oo
op
oq/oqs-provider
or
os oscavmgr: init at 0.4.1 (#339627) 2024-09-09 19:17:00 +02:00
ot
ou
ov
ow
pa
pc
pd
pe
pf/pfft
pg
ph photini: fix by using pyside6 (#332006) 2024-09-09 18:42:09 +02:00
pi
pk
pl
pm
pn
po
pp/ppsspp
pq
pr proton-ge-bin: GE-Proton9-12 -> GE-Proton9-13 2024-09-10 10:41:44 +00:00
ps
pt
pu
pv
pw
px/pxder
py
pz/pzip
qa/qadwaitadecorations
qb/qbittorrent-enhanced
qc/qcm
qd
qg/qgrep
qm/qmplay2
qn/qnial
qo/qodem
qp/qpoases
qq/qq
qr
qs
qt qtalarm: init at 2.5.1 (#337732) 2024-09-10 22:12:09 +08:00
qu
qw/qwerty-fr
r0/r0vm
r1/r10k
ra radicle-node: 1.0.0-rc.17 → 1.0.0 2024-09-10 13:54:51 +02:00
rc
rd/rdwatool
re recyclarr: 7.2.1 -> 7.2.3 (#328437) 2024-09-10 20:59:15 +02:00
rf/rfdump
rh/rHttp
ri
rk
rl/rl_json
rm
rn
ro roddhjav-apparmor-rules: 0-unstable-2024-08-30 -> 0-unstable-2024-09-08 (#340561) 2024-09-11 15:34:52 +05:30
rp/rpcs3
rq
rr/rrdtool
rs
rt
ru rustic: 0.8.0 -> 0.8.1 2024-09-10 13:08:26 +00:00
rw/rwpspread
ry
s0/s0ix-selftest-tool
s3
sa
sb sby: 0.44 -> 0.45 (#340966) 2024-09-10 12:13:16 +00:00
sc Merge master into staging-next 2024-09-09 14:31:17 +00:00
sd
se
sf
sg/sgfutils
sh shpool: 0.6.3 -> 0.7.0 (#339300) 2024-09-09 23:15:57 +08:00
si sirius: 7.6.0 -> 7.6.1 2024-09-10 02:45:25 +00:00
sk
sl
sm
sn snphost: 0.4.0 -> 0.5.0 2024-09-10 15:12:22 +02:00
so
sp sploitscan: 0.10.5 -> 0.11.0 2024-09-09 22:25:35 +00:00
sq sqlitestudio: init at 3.4.4 (#336505) 2024-09-11 15:01:31 +08:00
sr
ss
st stalwart-mail: 0.9.3 -> 0.9.4 2024-09-09 22:25:21 +02:00
su surfer: init at v0.2.0 2024-09-10 15:56:12 +08:00
sv
sw
sx
sy
t-/t-rex
ta
tb/tbump
tc
td
te testlib: init at 0.9.41 (#338072) 2024-09-11 19:47:40 +08:00
tg
th thrift-ls: change binary name to mimic upstream 2024-09-10 21:32:32 +10:00
ti
tk
tl
tm
to todesk: init at 4.7.2.0 (#310474) 2024-09-10 21:42:59 +08:00
tp
tr
ts
tt
tu
tw
tx
ty
u-/u-config
ub
uc
ud
ue
ug
uh/uhttpmock_1_0
ui
um/umpire
un
up
ur/urban-cli
us userborn: limit to Linux 2024-09-10 17:29:35 +02:00
ut
uu/uuu
uv/uv uv: 0.4.7 -> 0.4.8 2024-09-10 10:41:16 +00:00
uw
ux
va
vc
vd/vdhcoapp
ve
vf/vfkit
vg
vi
vk
vl
vm
vn
vo
vp
vr/vrcadvert
vs vscode-js-debug: 1.91.0 -> 1.93.0 (#332398) 2024-09-09 23:49:58 +02:00
vu
vv/vvvvvv
vw/vwsfriend
vz/vzic
wa warp-terminal: 0.2024.08.20.08.02.stable_00 -> 0.2024.09.03.08.02.stable_03 (#340319) 2024-09-11 15:17:06 +05:30
wb
wc/wcurl
we
wf/wf-touch
wg/wg-access-server
wh when-cli: init at 0.4.0 2024-09-10 08:53:13 +00:00
wi wit-bindgen: 0.30.0 -> 0.31.0 2024-09-10 02:58:18 +00:00
wl
wo
wp
wr/wrangler
ws
wt
wu/wush
wv
wx/wxc
wy/wyoming-satellite
x1/x16
x5/x509-limbo
xa
xc
xd
xe
xf/xfs-undelete
xh/xhosts
xi xine-ui: nixfmt-rfc-style 2024-09-10 11:52:32 -03:00
xl
xm
xn/xnlinkfinder
xo
xp
xr
xs
xt/xtf xtf: 0-unstable-2024-07-25 -> 0-unstable-2024-08-30 2024-09-09 13:27:21 +00:00
xu/xunit-viewer
xv/xviewer
xw
ya yandex-music: 5.14.0 -> 5.15.0 (#340968) 2024-09-10 10:45:09 +00:00
yc/ycmd
yd/ydotool
ye
yg
yj/yj
yo
yp/ypbind-mt
ys/ysfx
yt
yu
za
zb/zbus-xmlgen
zc
ze zed-editor: 0.151.2 -> 0.152.3 2024-09-10 15:54:47 -04:00
zf/zfind
zi
zl/zluda
zm/zmkBATx
zo zoom-us: move to by-name (#339851) 2024-09-11 10:07:50 +02:00
zp
zs zsh-wd: 0.7.1 -> 0.8.0 2024-09-10 16:18:24 +00:00
zu
zw/zwave-js-server
zx
README.md

Name-based package directories

The structure of this directory maps almost directly to top-level package attributes. Add new top-level packages to Nixpkgs using this mechanism whenever possible.

Packages found in the name-based structure are automatically included, without needing to be added to all-packages.nix. However if the implicit attribute defaults need to be changed for a package, this must still be declared in all-packages.nix.

Example

The top-level package pkgs.some-package may be declared by setting up this file structure:

pkgs
└── by-name
   ├── so
   ┊  ├── some-package
      ┊  └── package.nix

Where some-package is the package name and so is the lowercased 2-letter prefix of the package name.

The package.nix may look like this:

# A function taking an attribute set as an argument
{
  # Get access to top-level attributes for use as dependencies
  lib,
  stdenv,
  libbar,

  # Make this derivation configurable using `.override { enableBar = true }`
  enableBar ? false,
}:

# The return value must be a derivation
stdenv.mkDerivation {
  # ...
  buildInputs =
    lib.optional enableBar libbar;
}

You can also split up the package definition into more files in the same directory if necessary.

Once defined, the package can be built from the Nixpkgs root directory using:

nix-build -A some-package

See the general package conventions for more information on package definitions.

Changing implicit attribute defaults

The above expression is called using these arguments by default:

{
  lib = pkgs.lib;
  stdenv = pkgs.stdenv;
  libbar = pkgs.libbar;
}

But the package might need pkgs.libbar_2 instead. While the function could be changed to take libbar_2 directly as an argument, this would change the .override interface, breaking code like .override { libbar = ...; }. So instead it is preferable to use the same generic parameter name libbar and override its value in pkgs/top-level/all-packages.nix:

{
  libfoo = callPackage ../by-name/so/some-package/package.nix {
    libbar = libbar_2;
  };
}

Manual migration guidelines

Most packages are still defined in all-packages.nix and the category hierarchy. Since it would take a lot of contributor and reviewer time to migrate all packages manually, an automated migration is planned, though it is expected to still take some time to get done. If you're interested in helping out with this effort, please see this ticket.

Since only PRs to packages in pkgs/by-name can be automatically merged, if package maintainers would like to use this feature, they are welcome to migrate their packages to pkgs/by-name. To lessen PR traffic, they're encouraged to also perform some more general maintenance on the package in the same PR, though this is not required and must not be expected.

Note that definitions in all-packages.nix with custom arguments should not be removed. That is a backwards-incompatible change because it changes the .override interface. Such packages may still be moved to pkgs/by-name however, while keeping the definition in all-packages.nix. See also changing implicit attribute defaults.

Limitations

There's some limitations as to which packages can be defined using this structure:

  • Only packages defined using pkgs.callPackage. This excludes packages defined using pkgs.python3Packages.callPackage ....

    Instead:

    • Either change the package definition to work with pkgs.callPackage.
    • Or use the category hierarchy.
  • Only top-level packages. This excludes packages for other package sets like pkgs.pythonPackages.*.

    Refer to the definition and documentation of the respective package set to figure out how such packages can be declared.

Validation

CI performs certain checks on the pkgs/by-name structure. This is done using the nixpkgs-vet tool.

You can locally emulate the CI check using

$ ./ci/nixpkgs-vet.sh master

See here for more info.

Recommendation for new packages with multiple versions

These checks of the pkgs/by-name structure can cause problems in combination:

  1. New top-level packages using callPackage must be defined via pkgs/by-name.
  2. Packages in pkgs/by-name cannot refer to files outside their own directory.

This means that outside pkgs/by-name, multiple already-present top-level packages can refer to some common file. If you open a PR to another instance of such a package, CI will fail check 1, but if you try to move the package to pkgs/by-name, it will fail check 2.

This is often the case for packages with multiple versions, such as

{
  foo_1 = callPackage ../tools/foo/1.nix { };
  foo_2 = callPackage ../tools/foo/2.nix { };
}

The best way to resolve this is to not use callPackage directly, such that check 1 doesn't trigger. This can be done by using inherit on a local package set:

{
  inherit
    ({
      foo_1 = callPackage ../tools/foo/1.nix { };
      foo_2 = callPackage ../tools/foo/2.nix { };
    })
    foo_1
    foo_2
    ;
}

While this may seem pointless, this can in fact help with future package set refactorings, because it establishes a clear connection between related attributes.

Further possible refactorings

This is not required, but the above solution also allows refactoring the definitions into a separate file:

{
  inherit (import ../tools/foo pkgs)
    foo_1 foo_2;
}
# pkgs/tools/foo/default.nix
pkgs: {
  foo_1 = callPackage ./1.nix { };
  foo_2 = callPackage ./2.nix { };
}

Alternatively using callPackages if callPackage isn't used underneath and you want the same .override arguments for all attributes:

{
  inherit (callPackages ../tools/foo { })
    foo_1 foo_2;
}
# pkgs/tools/foo/default.nix
{
  stdenv
}: {
  foo_1 = stdenv.mkDerivation { /* ... */ };
  foo_2 = stdenv.mkDerivation { /* ... */ };
}

Exposing the package set

This is not required, but the above solution also allows exposing the package set as an attribute:

{
  foo-versions = import ../tools/foo pkgs;
  # Or using callPackages
  # foo-versions = callPackages ../tools/foo { };

  inherit (foo-versions) foo_1 foo_2;
}