#!/usr/bin/env nu

def main [] {
  if (hostname) == "kaladin" {
    df -h / | lines | get 1 | split column -r '\s' | get column5 | first
  } else {
    btrfs file df / | lines | first | split column -r '\s' | get column4 | str replace 'used=' '' | first
  }
}