dotnet-reference-remove(1)

📦
version 11.0.0~rc3 · 2 versions
, in alpine 3.24, centos-stream 10, centos-stream 9, fedora 43, fedora 44, nixpkgs unstable, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ dotnet-reference-remove — the manual page, but make it a group chat ✨

okay bestie, welcome to dotnet-reference-remove(1) from the .NET Documentation set 🎀 This one is a manual page, and yeah it applies to: ✔️ .NET 6 SDK and later versions. So if you're on .NET 6 or anything newer, you're in the right place, no cap 💅


💖 NAME 💖

dotnet-reference-remove — removes project-to-project (P2P) references. that's it, that's the whole job, and it does it beautifully 🦋

🚨 WAIT. READ THIS FIRST, FR FR. If you're using .NET 9 SDK or earlier, use the "verb first" form instead — that's dotnet-remove-reference. The "noun first" form only got introduced in .NET 10. For more information, see More consistent command order. Don't get caught out there bestie, iykyk 😭

🌸 SYNOPSIS 🌸

dotnet reference remove [-f|--framework <FRAMEWORK>] [--project <PROJECT>]
     <PROJECT_REFERENCES>

dotnet reference remove -h|--help

🫶 DESCRIPTION 🫶

The dotnet reference remove command is literally the convenient option for removing project references from a project. that's the vibe. that's the whole assignment. main character energy for a command that just… deletes a reference off your project file 👑


🍓 ARGUMENTS 🍓

  • PROJECT — the target project file. if you don't specify one, the command goes looking around the current directory for one. she's self-sufficient like that 💅
  • PROJECT_REFERENCES — the project-to-project (P2P) references you want gone. you can list one or multiple projects here, go off 👯 Glob patterns (https://en.wikipedia.org/wiki/Glob_(programming)) are supported on Unix/Linux based terminals ✨

💜 OPTIONS 💜

  • -?, -h, --help — prints out a description of how to use the command. the "help me bestie" button, iconic, we love her 🙈
  • -f, --framework <FRAMEWORK> — removes the reference only when targeting a specific framework, and you write that framework using the TFM format 🎯

🌈 EXAMPLES 🌈

  1. remove a project reference from the specified project:
dotnet reference remove lib/lib.csproj --project app/app.csproj
  1. remove multiple project references from the project in the current directory:
dotnet reference remove lib1/lib1.csproj lib2/lib2.csproj
  1. remove multiple project references using a glob pattern on Unix/Linux:
dotnet reference remove **/*.csproj` --project app/app.csproj

💀 heads up: that last example has a stray backtick in the original page (`*/.csproj``) — i copied it exactly, character for character, because copying is the one thing i will not freestyle. so if it looks weird, it's not me, it's canon 🫶

and that's the whole page bestie, you ate it up ⭐ sign-off time: this was dotnet-reference-remove(1), dated 2025-10-30 💖 go forth and remove those references, periodt 🎀

📦 where this page comes from