[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75H2X6KEKA7MVCEN2MSP1FY":3,"skill-same:01M75H2X6KEKA7MVCEN2MSP1FY":46},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":30,"ownerDescription":6,"updatedAt":31,"install":32,"resources":45},"01M75H2X6KEKA7MVCEN2MSP1FY","copy-to-output-directory",null,"Choosing an MSBuild CopyToOutputDirectory \u002F CopyToPublishDirectory mode: Never, PreserveNewest, Always, and IfDifferent (MSBuild 17.13+), plus $(SkipUnchangedFilesOnCopyAlways). USE FOR: removing the per-build Always copy perf hit; resetting output files mutated between builds. DO NOT USE FOR: general incremental-build diagnosis (use incremental-build); non-MSBuild build systems.","stanfish06\u002Fskillquarium","stanfish06","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F93099613?v=4","01M75F1CK4ZW109ZK3T26VN52F","Zhiyuan","01M75F1CM53VH6F79DZ8GXKKES",12,"MIT","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fcopy-to-output-directory\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: copy-to-output-directory\ndescription: \"Choosing an MSBuild CopyToOutputDirectory \u002F CopyToPublishDirectory mode: Never, PreserveNewest, Always, and IfDifferent (MSBuild 17.13+), plus $(SkipUnchangedFilesOnCopyAlways). USE FOR: removing the per-build Always copy perf hit; resetting output files mutated between builds. DO NOT USE FOR: general incremental-build diagnosis (use incremental-build); non-MSBuild build systems.\"\nlicense: MIT\n---\n\n# Choosing a CopyToOutputDirectory Mode\n\n## Overview\n\nThe `CopyToOutputDirectory` metadata (and its publish counterpart `CopyToPublishDirectory`) controls whether an item — `Content`, `None`, `EmbeddedResource`, or `Compile` — is copied next to your build output, and under what conditions the copy happens. Picking the wrong mode causes either stale files in `bin\u002F` or an unnecessary per-build performance hit.\n\nAs of **MSBuild 17.13 \u002F .NET SDK 9.0.2xx** there are four values:\n\n| Mode | Copies when… | Incremental cost | Typical use |\n| --- | --- | --- | --- |\n| `Never` (default) | Never | None | Files not needed at runtime |\n| `PreserveNewest` | Source is **newer** than destination (or destination missing) | Cheap (timestamp check) | The common case — source files you edit |\n| `Always` | **Every build**, unconditionally | Expensive — copies on every build even in no-op builds | Legacy workaround; avoid (see below) |\n| `IfDifferent` | Source **differs** from destination in either direction (newer **or** older, or size differs, or destination missing) | Cheap (timestamp + size check) | Destination may be mutated between builds |\n\n```xml\n\u003CItemGroup>\n  \u003CNone Include=\"appsettings.json\" CopyToOutputDirectory=\"PreserveNewest\" \u002F>\n  \u003CNone Include=\"testdata\\seed.db\"  CopyToOutputDirectory=\"IfDifferent\" \u002F>\n\u003C\u002FItemGroup>\n```\n\nYou can use either the attribute form shown above or the child-element form:\n\n```xml\n\u003CNone Include=\"testdata\\seed.db\">\n  \u003CCopyToOutputDirectory>IfDifferent\u003C\u002FCopyToOutputDirectory>\n\u003C\u002FNone>\n```\n\n## Why `Always` is usually the wrong choice\n\n`Always` re-copies the file on **every** build, including otherwise-clean incremental\u002Fno-op builds. On projects with many or large content files this is a measurable, recurring cost and a common cause of \"why is my no-op build not instant?\" reports.\n\nHistorically `Always` was the only way to handle a specific scenario: **the destination file can change between builds** — for example an SQLite database, a storage\u002Fstate file, or a config file that a test run mutates. With `PreserveNewest`, if the destination is modified (making its timestamp *newer* than the source) MSBuild will *not* restore the original source file, because the source is no longer newer. People reached for `Always` to force the file back into a known-good state — paying the copy cost on every build as a side effect.\n\n## `IfDifferent`: copy when different, in either direction\n\n`IfDifferent` is the targeted fix for that scenario. It copies the source over the destination whenever MSBuild considers the two **different** — whether the source is newer *or* older than the destination, whether the size differs, or the destination is missing — and skips the copy when the destination is unchanged per MSBuild's heuristic.\n\nUnder the hood the `_CopyDifferingSourceItemsToOutputDirectory` target uses the `Copy` task with `SkipUnchangedFiles=\"true\"`. That \"unchanged\" check is a **heuristic**: it compares **last-write timestamp and file size only** — not a content hash — so a destination that was edited to the same size and timestamp as the source is treated as unchanged and is *not* re-copied. In practice this restores a mutated destination back to the source version on the next build (the reason people reached for `Always`) while avoiding the unconditional per-build copy.\n\nUse `IfDifferent` when:\n\n- A test run or the app itself writes to the copied file (databases, caches, state\u002Fstorage files, editable config) and you want each build to reset it to the source version.\n- You were using `Always` purely as a \"keep the output in sync with the source\" mechanism, not because you truly need a copy on every single build.\n\n```xml\n\u003CItemGroup>\n  \u003C!-- Reset the fixture DB to the source copy whenever it has drifted,\n       but don't pay a copy on every no-op build. -->\n  \u003CNone Include=\"fixtures\\catalog.db\" CopyToOutputDirectory=\"IfDifferent\" \u002F>\n\u003C\u002FItemGroup>\n```\n\n## Globally softening `Always` with `$(SkipUnchangedFilesOnCopyAlways)`\n\nIf you have an existing codebase full of `CopyToOutputDirectory=\"Always\"` items and want the performance benefit without editing every item, set the property:\n\n```xml\n\u003CPropertyGroup>\n  \u003CSkipUnchangedFilesOnCopyAlways>true\u003C\u002FSkipUnchangedFilesOnCopyAlways>\n\u003C\u002FPropertyGroup>\n```\n\nThis makes the `_CopyOutOfDateSourceItemsToOutputDirectoryAlways` target pass `SkipUnchangedFiles=\"true\"` to its `Copy` task, so `Always` items are only copied when they actually differ — effectively giving `Always` the same skip-unchanged behavior as `IfDifferent`.\n\n- Default is `false` for backwards compatibility (classic `Always` = copy every build).\n- Set it in `Directory.Build.props` to opt an entire repo in at once.\n- Prefer converting individual items to `IfDifferent` when you can; use this property when a bulk, non-invasive opt-in is more practical.\n\n## How the modes flow through the build\n\n`GetCopyToOutputDirectoryItems` buckets each item by its `CopyToOutputDirectory` value. Three copy targets then do the work as dependencies of `_CopySourceItemsToOutputDirectory` (which is itself invoked by `CopyFilesToOutputDirectory`):\n\n- `_CopyOutOfDateSourceItemsToOutputDirectory` — `PreserveNewest` items (incremental via `Inputs`\u002F`Outputs` timestamp comparison).\n- `_CopyOutOfDateSourceItemsToOutputDirectoryAlways` — `Always` items (unconditional copy unless `$(SkipUnchangedFilesOnCopyAlways)` is `true`).\n- `_CopyDifferingSourceItemsToOutputDirectory` — `IfDifferent` items (`SkipUnchangedFiles=\"true\"`).\n\nAll copied files are registered in `FileWrites`, so `dotnet clean` removes them.\n\n**Transitive copy:** items marked `Always`, `PreserveNewest`, or `IfDifferent` also flow to referencing projects through `ProjectReference` (via `_CopyToOutputDirectoryTransitiveItems`). `Never` items do not. `IfDifferent` participates in ClickOnce publish item collection alongside `Always`\u002F`PreserveNewest`.\n\n## Version requirement\n\n`IfDifferent` and `$(SkipUnchangedFilesOnCopyAlways)` require **MSBuild 17.13 or later** (**.NET SDK 9.0.2xx+ \u002F Visual Studio 2022 17.13+**). On older toolsets the value is not recognized: it will not match the `Always`\u002F`PreserveNewest`\u002F`IfDifferent` conditions in the common targets, so the item is silently **not copied**. Gate usage on the toolset if you must support older SDKs, or require the minimum SDK via `global.json`.\n\n## Quick decision guide\n\n- Don't need the file at runtime → `Never` (or omit — it's the default).\n- Normal source file you edit → `PreserveNewest`.\n- Destination gets mutated between builds and must be reset to the source → `IfDifferent`.\n- You truly need a fresh copy on literally every build → `Always` (rare).\n- Stuck with lots of legacy `Always` and want the perf win without edits → keep `Always` but set `$(SkipUnchangedFilesOnCopyAlways)=true`.\n","# Choosing a CopyToOutputDirectory Mode\n\n## Overview\n\nThe `CopyToOutputDirectory` metadata (and its publish counterpart `CopyToPublishDirectory`) controls whether an item — `Content`, `None`, `EmbeddedResource`, or `Compile` — is copied next to your build output, and under what conditions the copy happens. Picking the wrong mode causes either stale files in `bin\u002F` or an unnecessary per-build performance hit.\n\nAs of **MSBuild 17.13 \u002F .NET SDK 9.0.2xx** there are four values:\n\n| Mode | Copies when… | Incremental cost | Typical use |\n| --- | --- | --- | --- |\n| `Never` (default) | Never | None | Files not needed at runtime |\n| `PreserveNewest` | Source is **newer** than destination (or destination missing) | Cheap (timestamp check) | The common case — source files you edit |\n| `Always` | **Every build**, unconditionally | Expensive — copies on every build even in no-op builds | Legacy workaround; avoid (see below) |\n| `IfDifferent` | Source **differs** from destination in either direction (newer **or** older, or size differs, or destination missing) | Cheap (timestamp + size check) | Destination may be mutated between builds |\n\n```xml\n\u003CItemGroup>\n  \u003CNone Include=\"appsettings.json\" CopyToOutputDirectory=\"PreserveNewest\" \u002F>\n  \u003CNone Include=\"testdata\\seed.db\"  CopyToOutputDirectory=\"IfDifferent\" \u002F>\n\u003C\u002FItemGroup>\n```\n\nYou can use either the attribute form shown above or the child-element form:\n\n```xml\n\u003CNone Include=\"testdata\\seed.db\">\n  \u003CCopyToOutputDirectory>IfDifferent\u003C\u002FCopyToOutputDirectory>\n\u003C\u002FNone>\n```\n\n## Why `Always` is usually the wrong choice\n\n`Always` re-copies the file on **every** build, including otherwise-clean incremental\u002Fno-op builds. On projects with many or large content files this is a measurable, recurring cost and a common cause of \"why is my no-op build not instant?\" reports.\n\nHistorically `Always` was the only way to handle a specific scenario: **the destination file can change between builds** — for example an SQLite database, a storage\u002Fstate file, or a config file that a test run mutates. With `PreserveNewest`, if the destination is modified (making its timestamp *newer* than the source) MSBuild will *not* restore the original source file, because the source is no longer newer. People reached for `Always` to force the file back into a known-good state — paying the copy cost on every build as a side effect.\n\n## `IfDifferent`: copy when different, in either direction\n\n`IfDifferent` is the targeted fix for that scenario. It copies the source over the destination whenever MSBuild considers the two **different** — whether the source is newer *or* older than the destination, whether the size differs, or the destination is missing — and skips the copy when the destination is unchanged per MSBuild's heuristic.\n\nUnder the hood the `_CopyDifferingSourceItemsToOutputDirectory` target uses the `Copy` task with `SkipUnchangedFiles=\"true\"`. That \"unchanged\" check is a **heuristic**: it compares **last-write timestamp and file size only** — not a content hash — so a destination that was edited to the same size and timestamp as the source is treated as unchanged and is *not* re-copied. In practice this restores a mutated destination back to the source version on the next build (the reason people reached for `Always`) while avoiding the unconditional per-build copy.\n\nUse `IfDifferent` when:\n\n- A test run or the app itself writes to the copied file (databases, caches, state\u002Fstorage files, editable config) and you want each build to reset it to the source version.\n- You were using `Always` purely as a \"keep the output in sync with the source\" mechanism, not because you truly need a copy on every single build.\n\n```xml\n\u003CItemGroup>\n  \u003C!-- Reset the fixture DB to the source copy whenever it has drifted,\n       but don't pay a copy on every no-op build. -->\n  \u003CNone Include=\"fixtures\\catalog.db\" CopyToOutputDirectory=\"IfDifferent\" \u002F>\n\u003C\u002FItemGroup>\n```\n\n## Globally softening `Always` with `$(SkipUnchangedFilesOnCopyAlways)`\n\nIf you have an existing codebase full of `CopyToOutputDirectory=\"Always\"` items and want the performance benefit without editing every item, set the property:\n\n```xml\n\u003CPropertyGroup>\n  \u003CSkipUnchangedFilesOnCopyAlways>true\u003C\u002FSkipUnchangedFilesOnCopyAlways>\n\u003C\u002FPropertyGroup>\n```\n\nThis makes the `_CopyOutOfDateSourceItemsToOutputDirectoryAlways` target pass `SkipUnchangedFiles=\"true\"` to its `Copy` task, so `Always` items are only copied when they actually differ — effectively giving `Always` the same skip-unchanged behavior as `IfDifferent`.\n\n- Default is `false` for backwards compatibility (classic `Always` = copy every build).\n- Set it in `Directory.Build.props` to opt an entire repo in at once.\n- Prefer converting individual items to `IfDifferent` when you can; use this property when a bulk, non-invasive opt-in is more practical.\n\n## How the modes flow through the build\n\n`GetCopyToOutputDirectoryItems` buckets each item by its `CopyToOutputDirectory` value. Three copy targets then do the work as dependencies of `_CopySourceItemsToOutputDirectory` (which is itself invoked by `CopyFilesToOutputDirectory`):\n\n- `_CopyOutOfDateSourceItemsToOutputDirectory` — `PreserveNewest` items (incremental via `Inputs`\u002F`Outputs` timestamp comparison).\n- `_CopyOutOfDateSourceItemsToOutputDirectoryAlways` — `Always` items (unconditional copy unless `$(SkipUnchangedFilesOnCopyAlways)` is `true`).\n- `_CopyDifferingSourceItemsToOutputDirectory` — `IfDifferent` items (`SkipUnchangedFiles=\"true\"`).\n\nAll copied files are registered in `FileWrites`, so `dotnet clean` removes them.\n\n**Transitive copy:** items marked `Always`, `PreserveNewest`, or `IfDifferent` also flow to referencing projects through `ProjectReference` (via `_CopyToOutputDirectoryTransitiveItems`). `Never` items do not. `IfDifferent` participates in ClickOnce publish item collection alongside `Always`\u002F`PreserveNewest`.\n\n## Version requirement\n\n`IfDifferent` and `$(SkipUnchangedFilesOnCopyAlways)` require **MSBuild 17.13 or later** (**.NET SDK 9.0.2xx+ \u002F Visual Studio 2022 17.13+**). On older toolsets the value is not recognized: it will not match the `Always`\u002F`PreserveNewest`\u002F`IfDifferent` conditions in the common targets, so the item is silently **not copied**. Gate usage on the toolset if you must support older SDKs, or require the minimum SDK via `global.json`.\n\n## Quick decision guide\n\n- Don't need the file at runtime → `Never` (or omit — it's the default).\n- Normal source file you edit → `PreserveNewest`.\n- Destination gets mutated between builds and must be reset to the source → `IfDifferent`.\n- You truly need a fresh copy on literally every build → `Always` (rare).\n- Stuck with lots of legacy `Always` and want the perf win without edits → keep `Always` but set `$(SkipUnchangedFilesOnCopyAlways)=true`.\n",{"name":5,"license":15,"description":7},"master","49e49abf2f670d429e0b7e2c0349739c3fdd5cbe","skills\u002Fcopy-to-output-directory",5,"https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium","https:\u002F\u002Fgithub.com\u002Fstanfish06","https:\u002F\u002Fwww.stanfish.dev\u002F","2026-11-14 21:31:37",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add stanfish06\u002Fskillquarium --skill copy-to-output-directory",{"tool":38,"command":39},"bunx","bunx skills add stanfish06\u002Fskillquarium --skill copy-to-output-directory",{"tool":41,"command":42},"pnpm","pnpm dlx skills add stanfish06\u002Fskillquarium --skill copy-to-output-directory","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fcopy-to-output-directory\u002FSKILL.md",true,[],[47,54,63,70,77,84],{"skillNo":48,"name":49,"nameZh":6,"description":50,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":51,"categories":52,"keywords":53,"publishedAt":19},"01M76ZJTRVA456GD7K8Y3EP82H","zarr-python","Stores and queries chunked N-D scientific arrays with Zarr-Python 3, including codecs, sharding, S3\u002FGCS storage, and NumPy\u002FDask\u002FXarray integration. Use for array layout, bounded I\u002FO, format migration, or scientific metadata preservation.","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fzarr-python\u002FSKILL.md",[],[],{"skillNo":55,"name":56,"nameZh":6,"description":57,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":58,"licenseFileUrl":59,"sourceHtmlUrl":60,"categories":61,"keywords":62,"publishedAt":19},"01M76ZJQZ15Q1HKC5V85NHE325","yeet","Publish local changes to GitHub by confirming scope, committing intentionally, pushing the branch, and opening a draft PR through the GitHub app from this plugin, with `gh` used only as a fallback where connector coverage is insufficient.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fyeet\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fyeet\u002FSKILL.md",[],[],{"skillNo":64,"name":65,"nameZh":6,"description":66,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":58,"licenseFileUrl":6,"sourceHtmlUrl":67,"categories":68,"keywords":69,"publishedAt":19},"01M76ZJ8ASZ4QYQ70Y6SBA4Z4S","xarray","N-dimensional labeled arrays and datasets in Python. Built on top of NumPy and Dask. It introduces labels in the form of dimensions, coordinates, and attributes on top of raw NumPy-like arrays, making data analysis in physical sciences more intuitive and less error-prone. Use for working with multi-dimensional scientific data, NetCDF\u002FGRIB\u002FZarr files, climate\u002Fweather\u002Foceanographic datasets, remote sensing, geospatial imaging, large out-of-memory datasets with Dask, and labeled array operations.","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fxarray\u002FSKILL.md",[],[],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":74,"categories":75,"keywords":76,"publishedAt":19},"01M76ZHFBXD6VXPQ02VCEG202B","writing-mstest-tests","Use when asked to fix, rewrite, update, improve, modernize, show corrected code for, or explain existing MSTest tests or MSTest-specific configuration. Use for \"review\" when corrected code or edits are wanted, even for one pasted assertion or passing tests with bad failure output. Covers expected\u002Factual labels; generic Boolean, collection, string, numeric, null, identity, exception, hard-cast, and object[] checks; TestContext\u002Flifecycle; timeout\u002Fcancellation; OS\u002FCI conditions, retry, cleanup, parallelization, MSTest.Sdk project setup, and MSTESTxxxx. Honor the installed MSTest version. DO NOT USE to design new test cases (code-testing), perform report-only audits, create project files rather than explain MSTest setup, run tests, migrate frameworks, or handle non-MSTest\u002Fnon-.NET code.","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fwriting-mstest-tests\u002FSKILL.md",[],[],{"skillNo":78,"name":79,"nameZh":6,"description":80,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":81,"categories":82,"keywords":83,"publishedAt":19},"01M76ZDFDF4N88RH6HSYGS7GP2","wgs-prs","End-to-end WGS to polygenic risk score pipeline. Takes paired-end FASTQ files (or a pre-existing VCF) through nf-core\u002Fsarek for variant calling, applies VCF QC (normalisation, hard filtering, Ti\u002FTv and Het\u002FHom checks), then computes polygenic risk scores via the PGS Catalog. Fills the FASTQ to VCF gap upstream of the gwas-prs skill.","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fwgs-prs\u002FSKILL.md",[],[],{"skillNo":85,"name":86,"nameZh":6,"description":87,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":58,"licenseFileUrl":88,"sourceHtmlUrl":89,"categories":90,"keywords":91,"publishedAt":19},"01M76ZCC1SC68J42QK4MDC8RCG","webapp-testing","Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fwebapp-testing\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fstanfish06\u002Fskillquarium\u002Fblob\u002Fmaster\u002Fskills\u002Fwebapp-testing\u002FSKILL.md",[],[]]