Laravel is not found

I installed Laravel but when I want to start a new project

find-the-command: “laravel” is not found locally, searching in repositories...
find-the-command: command not found: “laravel”

I get an error.

then I can add to the bashrc file

export PATH=“$HOME/.composer/vendor/bin:$PATH”

and then when I said “source bashrc”

~/.bashrc (line 5): Missing end to balance this if statement
if [ -x /usr/bin/starship ]; then
^^
from sourcing file ~/.bashrc
source: Error while reading file '/home/*/.bashrc'

I get an error. when I close that code block

~/.bashrc (line 2): $- is not a valid variable in fish.
[[ $- != *i* ]] && return
^
from sourcing file ~/.bashrc
source: Error while reading file '/home/*/.bashrc'

I get an error.

garuda-inxi;

System:
Kernel: 6.9.1-zen1-2-zen arch: x86_64 bits: 64 compiler: gcc v: 14.1.1
clocksource: tsc avail: acpi_pm
parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen
root=UUID=a96a4615-ec9d-45b6-8fff-214051405d4a rw rootflags=subvol=@
quiet resume=UUID=b192c665-62e5-40f1-b438-14cd9c435ad9 loglevel=3 ibt=off
Desktop: KDE Plasma v: 6.0.4 tk: Qt v: N/A info: frameworks v: 6.2.0
wm: kwin_wayland with: krunner vt: 1 dm: SDDM Distro: Garuda
base: Arch Linux
Machine:
Type: Laptop System: HP product: HP Pavilion Gaming Laptop 15-dk2xxx
v: Type1ProductConfigId serial: <superuser required> Chassis: type: 10
serial: <superuser required>
Mobo: HP model: 88E4 v: 76.41 serial: <superuser required>
part-nu: 4H0V9EA#AB8 uuid: <superuser required> UEFI: Insyde v: F.24
date: 10/04/2023
Battery:
ID-1: BAT1 charge: 41.8 Wh (98.8%) condition: 42.3/52.5 Wh (80.5%)
volts: 12.9 min: 11.6 model: Hewlett-Packard PABAS0241231 type: Li-ion
serial: <filter> status: charging
CPU:
Info: model: 11th Gen Intel Core i7-11370H bits: 64 type: MT MCP
arch: Tiger Lake gen: core 11 level: v4 note: check built: 2020
process: Intel 10nm family: 6 model-id: 0x8C (140) stepping: 1
microcode: 0xB6
Topology: cpus: 1x cores: 4 tpc: 2 threads: 8 smt: enabled cache:
L1: 320 KiB desc: d-4x48 KiB; i-4x32 KiB L2: 5 MiB desc: 4x1.2 MiB
L3: 12 MiB desc: 1x12 MiB
Speed (MHz): avg: 906 high: 2798 min/max: 400/4800 scaling:
driver: intel_pstate governor: powersave cores: 1: 400 2: 400 3: 400 4: 400
5: 2798 6: 524 7: 1928 8: 400 bogomips: 52838
Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Vulnerabilities: <filter>
Graphics:
Device-1: Intel TigerLake-LP GT2 [Iris Xe Graphics] vendor: Hewlett-Packard
driver: i915 v: kernel alternate: xe arch: Gen-12.1 process: Intel 10nm
built: 2020-21 ports: active: HDMI-A-1,eDP-1 empty: DP-1, DP-2, DP-3, DP-4
bus-ID: 0000:00:02.0 chip-ID: 8086:9a49 class-ID: 0300
Device-2: NVIDIA TU117M [GeForce GTX 1650 Mobile / Max-Q]
vendor: Hewlett-Packard driver: nvidia v: 550.78
alternate: nouveau,nvidia_drm non-free: 550.xx+ status: current (as of
2024-04; EOL~2026-12-xx) arch: Turing code: TUxxx process: TSMC 12nm FF
built: 2018-2022 bus-ID: 0000:01:00.0 chip-ID: 10de:1f9d class-ID: 0302
Device-3: Lite-On HP Wide Vision HD Camera driver: uvcvideo type: USB
rev: 2.0 speed: 480 Mb/s lanes: 1 mode: 2.0 bus-ID: 3-5:3 chip-ID: 04ca:707f
class-ID: 0e02 serial: <filter>
Display: wayland server: X.org v: 1.21.1.13 with: Xwayland v: 24.1.0
compositor: kwin_wayland driver: X: loaded: modesetting,nvidia
unloaded: nouveau alternate: fbdev,intel,nv,vesa dri: iris
gpu: i915,nvidia d-rect: 3520x2080 display-ID: 0
Monitor-1: HDMI-A-1 pos: bottom-r res: 1600x1000 size: N/A modes: N/A
Monitor-2: eDP-1 pos: primary,top-left res: 1920x1080 size: N/A modes: N/A
API: EGL v: 1.5 hw: drv: intel iris drv: nvidia platforms: device: 0
drv: nvidia device: 2 drv: iris device: 3 drv: swrast gbm: drv: nvidia
surfaceless: drv: nvidia wayland: drv: iris x11: drv: iris
inactive: device-1
API: OpenGL v: 4.6.0 compat-v: 4.5 vendor: intel mesa v: 24.0.7-arch1.3
glx-v: 1.4 direct-render: yes renderer: Mesa Intel Xe Graphics (TGL GT2)
device-ID: 8086:9a49 memory: 7.33 GiB unified: yes display-ID: :1.0
API: Vulkan v: 1.3.279 layers: 14 device: 0 type: integrated-gpu
name: Intel Xe Graphics (TGL GT2) driver: mesa intel v: 24.0.7-arch1.3
device-ID: 8086:9a49 surfaces: xcb,xlib,wayland device: 1
type: discrete-gpu name: NVIDIA GeForce GTX 1650 driver: nvidia v: 550.78
device-ID: 10de:1f9d surfaces: xcb,xlib,wayland device: 2 type: cpu
name: llvmpipe (LLVM 17.0.6 256 bits) driver: mesa llvmpipe
v: 24.0.7-arch1.3 (LLVM 17.0.6) device-ID: 10005:0000
surfaces: xcb,xlib,wayland
Audio:
Device-1: Intel Tiger Lake-LP Smart Sound Audio vendor: Hewlett-Packard
driver: snd_hda_intel v: kernel alternate: snd_soc_avs,snd_sof_pci_intel_tgl
bus-ID: 0000:00:1f.3 chip-ID: 8086:a0c8 class-ID: 0403
API: ALSA v: k6.9.1-zen1-2-zen status: kernel-api with: aoss
type: oss-emulator tools: N/A
Server-1: PipeWire v: 1.0.6 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: Realtek RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet
vendor: Hewlett-Packard driver: r8169 v: kernel port: 4000
bus-ID: 0000:02:00.0 chip-ID: 10ec:8168 class-ID: 0200
IF: eno1 state: down mac: <filter>
Device-2: Realtek RTL8852AE WiFi 6 802.11ax PCIe Adapter
vendor: Hewlett-Packard driver: rtw89_8852ae v: kernel port: 3000
bus-ID: 0000:03:00.0 chip-ID: 10ec:a85a class-ID: 0280
IF: wlo1 state: up mac: <filter>
Info: services: NetworkManager, smbd, systemd-timesyncd, wpa_supplicant
Bluetooth:
Device-1: Realtek Bluetooth Radio driver: btusb v: 0.8 type: USB rev: 1.0
speed: 12 Mb/s lanes: 1 mode: 1.1 bus-ID: 3-10:4 chip-ID: 0bda:385a
class-ID: e001 serial: <filter>
Report: btmgmt ID: hci0 rfk-id: 0 state: down bt-service: enabled,running
rfk-block: hardware: no software: yes address: <filter> bt-v: 5.2 lmp-v: 11
status: discoverable: no pairing: no
RAID:
Hardware-1: Intel Volume Management Device NVMe RAID Controller driver: vmd
v: 0.6 port: N/A bus-ID: 0000:00:0e.0 chip-ID: 8086:9a0b rev: class-ID: 0104
Drives:
Local Storage: total: 476.94 GiB used: 80.31 GiB (16.8%)
SMART Message: Unable to run smartctl. Root privileges required.
ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Samsung
model: MZVLQ512HALU-000H1 size: 476.94 GiB block-size: physical: 512 B
logical: 512 B speed: 31.6 Gb/s lanes: 4 tech: SSD serial: <filter>
fw-rev: HPS4NFXV temp: 45.9 C scheme: GPT
Partition:
ID-1: / raw-size: 467.84 GiB size: 467.84 GiB (100.00%)
used: 80.31 GiB (17.2%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:2
ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
used: 584 KiB (0.2%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1
ID-3: /home raw-size: 467.84 GiB size: 467.84 GiB (100.00%)
used: 80.31 GiB (17.2%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:2
ID-4: /var/log raw-size: 467.84 GiB size: 467.84 GiB (100.00%)
used: 80.31 GiB (17.2%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:2
ID-5: /var/tmp raw-size: 467.84 GiB size: 467.84 GiB (100.00%)
used: 80.31 GiB (17.2%) fs: btrfs dev: /dev/nvme0n1p2 maj-min: 259:2
Swap:
Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default) zswap: no
ID-1: swap-1 type: zram size: 7.51 GiB used: 1.13 GiB (15.1%)
priority: 100 comp: zstd avail: lzo,lzo-rle,lz4,lz4hc,842 max-streams: 8
dev: /dev/zram0
ID-2: swap-2 type: partition size: 8.8 GiB used: 0 KiB (0.0%) priority: -2
dev: /dev/nvme0n1p3 maj-min: 259:3
Sensors:
System Temperatures: cpu: 64.0 C mobo: N/A
Fan Speeds (rpm): cpu: 0 fan-2: 0
Info:
Memory: total: 8 GiB available: 7.51 GiB used: 4.04 GiB (53.8%)
Processes: 308 Power: uptime: 46m states: freeze,mem,disk suspend: s2idle
wakeups: 0 hibernate: platform avail: shutdown, reboot, suspend, test_resume
image: 2.96 GiB services: org_kde_powerdevil, power-profiles-daemon,
upowerd Init: systemd v: 255 default: graphical tool: systemctl
Packages: pm: pacman pkgs: 1977 libs: 582 tools: octopi,paru Compilers:
clang: 17.0.6 gcc: 14.1.1 Shell: garuda-inxi default: fish v: 3.7.1
running-in: konsole inxi: 3.3.34
Garuda (2.6.26-1):
System install date:     2024-05-11
Last full system update: 2024-05-23
Is partially upgraded:   No
Relevant software:       snapper NetworkManager dracut nvidia-dkms
Windows dual boot:       No/Undetected
Failed units:

sorry for my english and linux knowledge*

Maybe this happens because in Konsole your shell is fish not bash.
Enter into a bash shell and try again or change the shell in konsole with Settings → Edit Current Profile →General → Command.

1 Like

export PATH=“$HOME/.composer/vendor/bin:$PATH” is the wrong path.

the correct one
export PATH=“$HOME/.config/composer/vendor/bin:$PATH”

I added bashrc and bash_profile and then source and of course I had to change fish.

thank you.

It’s unusual to add a ~/.config directory to PATH. It is possible this application has been set up oddly.

Anyway, if you are going to be using Fish an easier way to set this up would be to run fish_add_path against it.

fish_add_path ~/.config/composer/vendor/bin

That should add it to the path for you. No need to source anything or change shells or whatever, just open the terminal and carry on with your work. fish_add_path - add to the path — fish-shell 3.7.0 documentation

3 Likes

Thank you very much. It worked.

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