Skip to content

Repository files navigation

wy

wy is a Windows-first CLI package manager frontend inspired by yay on Arch Linux. It presents a unified command surface over real Windows package sources, starting with WinGet and Chocolatey, with a clean backend abstraction ready for Scoop.

Features

  • Friendly commands such as wy search firefox and wy install git
  • yay-style compatibility aliases such as wy -Ss firefox and wy -Syu
  • Multi-backend search and package resolution across WinGet and Chocolatey
  • Explicit backend targeting with --backend winget|choco|scoop
  • Interactive ambiguity handling with a numbered picker
  • --non-interactive mode for automation
  • --json output mode for scripting
  • Startup backend diagnostics so missing tools are obvious

Project Structure

  • src/Wy.Cli: entrypoint, help text, startup wiring, app orchestration
  • src/Wy.Core: domain models, contracts, command parsing, resolver logic
  • src/Wy.Infrastructure: process execution, config loading, backend implementations, console UX
  • tests/Wy.Tests: unit tests for parser and resolver behavior

Supported Commands

Friendly syntax

  • wy search <query>
  • wy install <package>
  • wy remove <package>
  • wy info <package>
  • wy upgrade
  • wy update-db
  • wy list-upgrades

yay compatibility

  • wy -Ss <query> -> wy search <query>
  • wy -S <package> -> wy install <package>
  • wy -R <package> -> wy remove <package>
  • wy -Qi <package> -> wy info <package>
  • wy -Syu -> wy upgrade --refresh
  • wy -Sy -> wy update-db
  • wy -Qu -> wy list-upgrades

Backend Overview

WinGet

  • Search: winget search --query <query> --accept-source-agreements --disable-interactivity
  • Install: winget install --id <id> --exact
  • Remove: winget uninstall --id <id> --exact
  • Info: winget show --id <id> --accept-source-agreements --disable-interactivity
  • Upgrade: winget upgrade --all
  • Refresh: winget source update
  • List upgrades: winget upgrade --accept-source-agreements --disable-interactivity

Chocolatey

  • Search: choco search <query> --limit-output
  • Install: choco install <id> -y
  • Remove: choco uninstall <id> -y
  • Info: choco info <id> --limit-output
  • Upgrade: choco upgrade all -y
  • Refresh: treated as implicit
  • List upgrades: choco outdated --limit-output

Scoop

Scoop is scaffolded as a backend slot so the architecture supports a third source cleanly, but command implementations are intentionally left incomplete in this first milestone.

Configuration

The config file lives at %AppData%\\wy\\config.json.

Example:

{
  "defaultBackend": "winget",
  "enabledBackends": ["winget", "choco"],
  "nonInteractive": false,
  "colorEnabled": true,
  "verboseLogging": false,
  "jsonOutput": false,
  "processTimeoutSeconds": 600
}

A sample config is also included at config.sample.json.

Build

Requirements:

  • .NET 8 SDK
  • Windows
  • winget and/or choco installed and available on PATH

Commands:

dotnet restore
dotnet build wy.sln
dotnet test wy.sln

Run:

dotnet run --project .\src\Wy.Cli\Wy.Cli.csproj -- search firefox
dotnet run --project .\src\Wy.Cli\Wy.Cli.csproj -- -Syu

Build a release installer:

.\scripts\build-release.ps1

This produces:

  • a self-contained single-file app in artifacts\publish\win-x64
  • a per-user Windows .exe installer in artifacts\installer

The installer installs wy into %LocalAppData%\Programs\wy and adds that directory to the current user's PATH.

Usage Examples

wy search firefox
wy install git --backend winget
wy remove vlc --backend choco
wy info neovim
wy upgrade --refresh
wy update-db
wy list-upgrades
wy -Ss firefox
wy -S git
wy -R vlc
wy -Qi git
wy -Syu

Notes

  • This code shells out to the real package managers. It does not fake installs.
  • Resolver behavior is centralized in Wy.Core so new backends can be added without redesigning the CLI.
  • Chocolatey parsing is isolated in its backend, and the WinGet backend is written to support current Windows client output where JSON is not available for all commands.

About

yay for windows

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages