Soenneker.Managers.HashSaving
11.0.1422
Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package Soenneker.Managers.HashSaving --version 11.0.1422
NuGet\Install-Package Soenneker.Managers.HashSaving -Version 11.0.1422
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Managers.HashSaving" Version="11.0.1422" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Managers.HashSaving" Version="11.0.1422" />
<PackageReference Include="Soenneker.Managers.HashSaving" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Soenneker.Managers.HashSaving --version 11.0.1422
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Soenneker.Managers.HashSaving, 11.0.1422"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Soenneker.Managers.HashSaving@11.0.1422
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Soenneker.Managers.HashSaving&version=11.0.1422
#tool nuget:?package=Soenneker.Managers.HashSaving&version=11.0.1422
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Soenneker.Managers.HashSaving
Writes a precomputed hash into a repository checkout, optionally removes packaged resources, then commits and pushes the change.
Install
dotnet add package Soenneker.Managers.HashSaving
Usage
using Microsoft.Extensions.DependencyInjection;
using Soenneker.Managers.HashSaving.Abstract;
using Soenneker.Managers.HashSaving.Registrars;
services.AddHashSavingManagerAsSingleton();
IHashSavingManager hashes =
serviceProvider.GetRequiredService<IHashSavingManager>();
await hashes.SaveHashToGitRepoWithoutClearingResources(
gitDirectory: repositoryPath,
newHash: verifiedHash,
hashFileName: "hash.txt",
name: "Automation",
email: "automation@example.com",
token: githubToken,
cancellationToken);
Each method writes the hash and immediately commits and pushes all working-tree changes using the message Updates hash for new version. Use it only with a disposable, dedicated checkout whose complete contents are intended for that commit.
What you get
IHashSavingManager— Handles hashing and saving.HashSavingManagerRegistrar— Handles hashing and saving.
API at a glance
| API | What it does | Result / important behavior |
|---|---|---|
IHashSavingManager.SaveHashToGitRepoWithoutClearingResources(gitDirectory, newHash, hashFileName, name, email, token, cancellationToken) |
Saves hash To Git Repo Without Clearing Resources. | A task that completes when the hash to git repo without clearing resources has been saved. |
IHashSavingManager.SaveHashToGitRepoAsFile(gitDirectory, libraryName, newHash, fileName, hashFileName, name, email, username, token, cancellationToken) |
Saves hash To Git Repo As File. | A task that completes when the hash to git repo as file has been saved. |
IHashSavingManager.SaveHashToGitRepoAsDirectory(gitDirectory, newHash, targetDir, hashFileName, name, email, username, token, cancellationToken) |
Saves hash To Git Repo As Directory. | A task that completes when the hash to git repo as directory has been saved. |
HashSavingManagerRegistrar.AddHashSavingManagerAsSingleton(services) |
Adds IHashSavingManager as a singleton service. |
The same service collection, so additional registrations can be chained. |
HashSavingManagerRegistrar.AddHashSavingManagerAsScoped(services) |
Adds IHashSavingManager as a scoped service. |
The same service collection, so additional registrations can be chained. |
Practical notes
SaveHashToGitRepoWithoutClearingResources()leaves packaged resources in place.SaveHashToGitRepoAsFile()deletessrc/<libraryName>/Resources/<fileName>before committing.SaveHashToGitRepoAsDirectory()deletes the supplied resource directory before committing.- Hash and resource paths are required to remain inside
gitDirectory; traversal and outside paths are rejected before deletion. usernameis retained for API compatibility but is not used.nameandemailset commit attribution;tokenauthenticates the push.- Cancellation can stop the operation between local mutation, commit, and push. Run recovery or discard the dedicated checkout rather than assuming rollback.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net11.0 is compatible. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net11.0
- Soenneker.Git.Util (>= 11.0.3923)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Soenneker.Managers.HashSaving:
| Package | Downloads |
|---|---|
|
Soenneker.Managers.Runners
Handles Runner operations and coordination |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 11.0.1425 | 0 | 11/30/2026 |
| 11.0.1424 | 0 | 11/30/2026 |
| 11.0.1423 | 0 | 11/30/2026 |
| 11.0.1422 | 0 | 11/30/2026 |
| 11.0.1421 | 0 | 11/30/2026 |
| 11.0.1420 | 0 | 11/29/2026 |
| 11.0.1419 | 1,555 | 11/28/2026 |
| 11.0.1418 | 910 | 11/27/2026 |
| 11.0.1417 | 577 | 11/26/2026 |
| 11.0.1416 | 2,091 | 11/22/2026 |
| 11.0.1415 | 874 | 11/21/2026 |
| 11.0.1414 | 1,426 | 11/19/2026 |
| 11.0.1413 | 386 | 11/19/2026 |
| 11.0.1412 | 92 | 11/19/2026 |
| 11.0.1411 | 209 | 11/18/2026 |
| 11.0.1410 | 260 | 11/18/2026 |
| 11.0.1408 | 1,216 | 11/18/2026 |
| 11.0.1407 | 389 | 11/18/2026 |
| 11.0.1406 | 2,568 | 11/15/2026 |
| 11.0.1405 | 619 | 11/15/2026 |
Loading failed
Updated Soenneker.Git.Util to 11.0.3923