#!/bin/bash
# B3D Arch Linux Installation via AUR
set -euo pipefail

echo "🔧 B3D Arch Linux Installation via AUR"

if ! command -v yay >/dev/null 2>&1; then
  echo "❌ yay not found. Installing yay..."
  sudo pacman -S --noconfirm base-devel git
  cd /tmp
  rm -rf yay
  git clone https://aur.archlinux.org/yay.git
  cd yay
  makepkg -si --noconfirm
fi

echo "📦 Installing/Updating b3d via yay..."
yay -S --noconfirm b3d

echo "✅ Done. Run: b3d --version"
