Bug 2548453

Summary: nix startup script missing for fish shell
Product: [Fedora] Fedora Reporter: Nitin KM <muchelinitin>
Component: nixAssignee: Jens Petersen <petersen>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: unspecified    
Version: 44CC: muchelinitin, petersen
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: nix-2.31.6-1.el10_4 nix-2.31.6-1.el10_3 nix-2.35.3-2.fc44 nix-2.31.6-1.el10_2 nix-2.35.3-2.fc45 Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2026-10-21 01:00:24 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Nitin KM 2026-10-09 10:24:54 UTC
Description of problem:
nix startup scripts are placed under /etc/profile.d/ and are sourced by bash/zsh, but not by fish.
SDDM and PLM worked fine, when I set fish as the default shell on Konsole as they apparently source the files present under /etc/profile.d
With GDM, it isn't the case. GDM doesn't source these scripts, and without a fish initialization script for nix, the nix packages aren't on path and nix overall is dysfunctional.

Version-Release number of selected component (if applicable):
It is reproducible with current nix version on Fedora 44 - nix-2.34.8-1.fc44.src.rpm


How reproducible:
Always

Steps to Reproduce:
1. install fish shell
2. install nix 
   (after fish, as some fish scripts aren't produced if fish isn't present)
3. add some package to your nix profile, using `nix profile add...`
3. launch fish as a login shell

Actual results:
nix env vars aren't set, and the package installed in the step above isn't on the path. But with bash, it works fine

Expected results:
nix initialization script should be sourced, and the installed pkg should be present on path. nix/bin path isn't on path wholly.

Additional info:
the upstream installer places a file at /etc/fish/conf.d/nix.fish with the following content to initialize nix on fish shell:
```
# Nix
if test -e '/nix/var/nix/profiles/default/etc/profile.d/nix-daemon.fish'
  . '/nix/var/nix/profiles/default/etc/profile.d/nix-daemon.fish'
end
# End Nix
```

The meson installer apparently skips this, as reported by Jens Peterson: https://github.com/NixOS/nix/issues/16576
The upstream installer script does still place other fish scripts into /etc/profile.d/, namely (another) nix.fish and nix-daemon.fish, although this dir isn't sourced by fish shell at all. These have a lock to not run the source function if the nix env vars are already present.
I'm not aware of the difference between these two scripts in the /etc/profile.d dir, but if they have differing behaviour, moving them into /etc/fish/conf.d or  /etc/fish/vendor-conf.d/ might be a bad idea, as the first script that was sourced takes precedence.

Comment 1 Fedora Update System 2026-10-17 11:39:59 UTC
FEDORA-2026-d34d705a38 (nix-2.35.3-1.fc45) has been submitted as an update to Fedora 45.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-d34d705a38

Comment 2 Fedora Update System 2026-10-17 14:36:10 UTC
FEDORA-2026-d9fe9e0ac3 (nix-2.35.3-2.fc44) has been submitted as an update to Fedora 44.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-d9fe9e0ac3

Comment 3 Fedora Update System 2026-10-17 17:08:08 UTC
FEDORA-EPEL-2026-ffed74cdfb (nix-2.31.6-1.el10_4) has been submitted as an update to Fedora EPEL 10.4.
https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2026-ffed74cdfb

Comment 4 Fedora Update System 2026-10-17 17:33:30 UTC
FEDORA-EPEL-2026-51b9011519 (nix-2.31.6-1.el10_3) has been submitted as an update to Fedora EPEL 10.3.
https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2026-51b9011519

Comment 5 Fedora Update System 2026-10-18 01:51:46 UTC
FEDORA-2026-d34d705a38 has been pushed to the Fedora 45 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-d34d705a38`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-d34d705a38

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 6 Fedora Update System 2026-10-18 01:58:37 UTC
FEDORA-EPEL-2026-ffed74cdfb has been pushed to the Fedora EPEL 10.4 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2026-ffed74cdfb

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 7 Fedora Update System 2026-10-18 02:09:10 UTC
FEDORA-EPEL-2026-51b9011519 has been pushed to the Fedora EPEL 10.3 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2026-51b9011519

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 8 Fedora Update System 2026-10-18 02:46:48 UTC
FEDORA-2026-d9fe9e0ac3 has been pushed to the Fedora 44 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-d9fe9e0ac3`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-d9fe9e0ac3

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 9 Fedora Update System 2026-10-18 05:04:12 UTC
FEDORA-EPEL-2026-06f144fbdf (nix-2.31.6-1.el10_2) has been submitted as an update to Fedora EPEL 10.2.
https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2026-06f144fbdf

Comment 10 Fedora Update System 2026-10-19 02:03:57 UTC
FEDORA-EPEL-2026-06f144fbdf has been pushed to the Fedora EPEL 10.2 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2026-06f144fbdf

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 11 Fedora Update System 2026-10-21 01:00:24 UTC
FEDORA-EPEL-2026-ffed74cdfb (nix-2.31.6-1.el10_4) has been pushed to the Fedora EPEL 10.4 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 12 Fedora Update System 2026-10-26 00:42:13 UTC
FEDORA-EPEL-2026-51b9011519 (nix-2.31.6-1.el10_3) has been pushed to the Fedora EPEL 10.3 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 13 Fedora Update System 2026-10-26 01:08:00 UTC
FEDORA-2026-d9fe9e0ac3 (nix-2.35.3-2.fc44) has been pushed to the Fedora 44 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 14 Fedora Update System 2026-10-27 00:47:36 UTC
FEDORA-EPEL-2026-06f144fbdf (nix-2.31.6-1.el10_2) has been pushed to the Fedora EPEL 10.2 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 15 Fedora Update System 2026-10-31 18:45:37 UTC
FEDORA-2026-d34d705a38 (nix-2.35.3-2.fc45) has been pushed to the Fedora 45 stable repository.
If problem still persists, please make note of it in this bug report.