.bashrc $PATH not updaing for nvm installation

I’ve tried to install nvm via nvm.sh, but nvm continues to not get added to $PATH:

which: no nvm in (/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr
/bin/vendor_perl:/usr/bin/core_perl)

Using the default fish terminal emulator, how can I proceed to install nvm in Garuda linux?

System:
Kernel: 6.3.6-zen1-1-zen arch: x86_64 bits: 64 compiler: gcc v: 13.1.1
parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen
root=UUID=b0aff0a6-c230-4053-b43e-55214acd87fb rw rootflags=subvol=@
quiet quiet splash rd.udev.log_priority=3 vt.global_cursor_default=0
resume=UUID=c521b8b7-0aed-4d7d-b959-564847a6d85d loglevel=3 ibt=off
Desktop: KDE Plasma v: 5.27.5 tk: Qt v: 5.15.9 wm: kwin_wayland vt: 2
dm: SDDM Distro: Garuda Linux base: Arch Linux
Machine:
Type: Desktop Mobo: ASUSTeK model: MAXIMUS VIII HERO v: Rev 1.xx
serial: <superuser required> UEFI: American Megatrends v: 3401
date: 01/25/2017
CPU:
Info: model: Intel Core i7-7700K bits: 64 type: MT MCP arch: Kaby Lake
gen: core 7 level: v3 note: check built: 2018 process: Intel 14nm family: 6
model-id: 0x9E (158) stepping: 9 microcode: 0xF2
Topology: cpus: 1x cores: 4 tpc: 2 threads: 8 smt: enabled cache:
L1: 256 KiB desc: d-4x32 KiB; i-4x32 KiB L2: 1024 KiB desc: 4x256 KiB
L3: 8 MiB desc: 1x8 MiB
Speed (MHz): avg: 2221 high: 2364 min/max: 800/4500 scaling:
driver: intel_pstate governor: powersave cores: 1: 2200 2: 2364 3: 2205
4: 2284 5: 2281 6: 2346 7: 2000 8: 2091 bogomips: 67200
Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Vulnerabilities: <filter>
Graphics:
Device-1: AMD Navi 21 [Radeon RX 6800/6800 XT / 6900 XT] vendor: Gigabyte
driver: amdgpu v: kernel arch: RDNA-2 code: Navi-2x process: TSMC n7 (7nm)
built: 2020-22 pcie: gen: 4 speed: 16 GT/s lanes: 16 ports:
active: DP-1,DP-2,HDMI-A-1 empty: HDMI-A-2 bus-ID: 03:00.0
chip-ID: 1002:73bf class-ID: 0300
Device-2: Microsoft LifeCam HD-3000 driver: snd-usb-audio,uvcvideo
type: USB rev: 2.0 speed: 480 Mb/s lanes: 1 mode: 2.0 bus-ID: 1-8.2.4.3:10
chip-ID: 045e:0779 class-ID: 0102
Display: wayland server: X.org v: 1.21.1.8 with: Xwayland v: 23.1.2
compositor: kwin_wayland driver: X: loaded: amdgpu
unloaded: modesetting,radeon alternate: fbdev,vesa dri: radeonsi
gpu: amdgpu d-rect: 5560x4440 display-ID: 0
Monitor-1: DP-1 pos: middle-c res: 2560x1440 size: N/A modes: N/A
Monitor-2: DP-2 pos: bottom-r res: 1920x1080 size: N/A modes: N/A
Monitor-3: HDMI-A-1 pos: primary,top-left res: 1080x1920 size: N/A
modes: N/A
API: OpenGL v: 4.6 Mesa 23.1.1 renderer: AMD Radeon RX 6800 XT (navi21
LLVM 15.0.7 DRM 3.52 6.3.6-zen1-1-zen) direct-render: Yes
Audio:
Device-1: Intel 100 Series/C230 Series Family HD Audio vendor: ASUSTeK
driver: snd_hda_intel v: kernel alternate: snd_soc_avs bus-ID: 00:1f.3
chip-ID: 8086:a170 class-ID: 0403
Device-2: AMD Navi 21/23 HDMI/DP Audio driver: snd_hda_intel v: kernel
pcie: gen: 4 speed: 16 GT/s lanes: 16 bus-ID: 03:00.1 chip-ID: 1002:ab28
class-ID: 0403
Device-3: Microsoft LifeCam HD-3000 driver: snd-usb-audio,uvcvideo
type: USB rev: 2.0 speed: 480 Mb/s lanes: 1 mode: 2.0 bus-ID: 1-8.2.4.3:10
chip-ID: 045e:0779 class-ID: 0102
API: ALSA v: k6.3.6-zen1-1-zen status: kernel-api with: aoss
type: oss-emulator tools: N/A
Server-1: PipeWire v: 0.3.71 status: active with: 1: pipewire-pulse
status: active 2: wireplumber status: active 3: pipewire-alsa type: plugin
4: pw-jack type: plugin tools: pactl,pw-cat,pw-cli,wpctl
Network:
Device-1: Intel Ethernet I219-V vendor: ASUSTeK driver: e1000e v: kernel
port: N/A bus-ID: 00:1f.6 chip-ID: 8086:15b8 class-ID: 0200
IF: enp0s31f6 state: up speed: 1000 Mbps duplex: full mac: <filter>
Drives:
Local Storage: total: 10.46 TiB used: 9.75 TiB (93.2%)
SMART Message: Unable to run smartctl. Root privileges required.
ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Intel model: SSDPEKNW010T8
size: 953.87 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s
lanes: 4 tech: SSD serial: <filter> fw-rev: 002C temp: 35.9 C scheme: GPT
ID-2: /dev/sda maj-min: 8:0 vendor: Intel model: SSDSC2BP480G4
size: 447.13 GiB block-size: physical: 512 B logical: 512 B speed: 6.0 Gb/s
tech: SSD serial: <filter> fw-rev: 0420 scheme: GPT
ID-3: /dev/sdb maj-min: 8:16 vendor: Western Digital
model: WD30EFRX-68EUZN0 size: 2.73 TiB block-size: physical: 4096 B
logical: 512 B speed: 6.0 Gb/s tech: HDD rpm: 5400 serial: <filter>
fw-rev: 0A82 scheme: GPT
ID-4: /dev/sdc maj-min: 8:32 vendor: Seagate model: ST3000DM001-1CH166
size: 2.73 TiB block-size: physical: 4096 B logical: 512 B speed: 6.0 Gb/s
tech: HDD rpm: 7200 serial: <filter> fw-rev: CC29 scheme: GPT
ID-5: /dev/sdd maj-min: 8:48 vendor: Seagate model: ST4000DX001-1CE168
size: 3.64 TiB block-size: physical: 4096 B logical: 512 B speed: 6.0 Gb/s
tech: HDD rpm: 5900 serial: <filter> fw-rev: CC44 scheme: GPT
Partition:
ID-1: / raw-size: 412.42 GiB size: 412.42 GiB (100.00%)
used: 31.4 GiB (7.6%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
used: 580 KiB (0.2%) fs: vfat dev: /dev/sda1 maj-min: 8:1
ID-3: /home raw-size: 412.42 GiB size: 412.42 GiB (100.00%)
used: 31.4 GiB (7.6%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
ID-4: /var/log raw-size: 412.42 GiB size: 412.42 GiB (100.00%)
used: 31.4 GiB (7.6%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
ID-5: /var/tmp raw-size: 412.42 GiB size: 412.42 GiB (100.00%)
used: 31.4 GiB (7.6%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
Swap:
Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default)
ID-1: swap-1 type: zram size: 31.29 GiB used: 188 MiB (0.6%) priority: 100
dev: /dev/zram0
ID-2: swap-2 type: partition size: 34.41 GiB used: 0 KiB (0.0%)
priority: -2 dev: /dev/sda3 maj-min: 8:3
Sensors:
System Temperatures: cpu: 43.0 C mobo: N/A gpu: amdgpu temp: 60.0 C
mem: 56.0 C
Fan Speeds (RPM): N/A gpu: amdgpu fan: 0
Info:
Processes: 291 Uptime: 16m wakeups: 0 Memory: available: 31.29 GiB
used: 5.55 GiB (17.7%) Init: systemd v: 253 default: graphical
tool: systemctl Compilers: gcc: 13.1.1 Packages: pm: pacman pkgs: 1840
libs: 548 tools: octopi,paru Shell: fish v: 3.6.1 default: Bash v: 5.1.16
running-in: konsole inxi: 3.3.27
Garuda (2.6.16-1):
System install date:     2023-05-24
Last full system update: 2023-06-09 ↻
Is partially upgraded:   No
Relevant software:       snapper NetworkManager dracut
Windows dual boot:       Probably (Run as root to verify)

You can add to a Fish path like so:

https://fishshell.com/docs/current/cmds/fish_add_path.html

2 Likes

NVM doesn't support fish. If you had read the project's readme on github they explain the reason for not being able to do that and provided alternatives to use in fish.

Though that doesn't mean you can't use nvm. If you have looked in your ~/.bashrc you would have noticed that nvm added it's path at the end of file. You can simply type

bash

In terminal to use bash and then nvm commands.

6 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.