Sunmeat.Portal 1.0.0

Prefix Reserved
dotnet add package Sunmeat.Portal --version 1.0.0
                    
NuGet\Install-Package Sunmeat.Portal -Version 1.0.0
                    
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="Sunmeat.Portal" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Sunmeat.Portal" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Sunmeat.Portal" />
                    
Project file
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 Sunmeat.Portal --version 1.0.0
                    
#r "nuget: Sunmeat.Portal, 1.0.0"
                    
#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 Sunmeat.Portal@1.0.0
                    
#: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=Sunmeat.Portal&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Sunmeat.Portal&version=1.0.0
                    
Install as a Cake Tool

Sunmeat.Portal logo

Sunmeat.Portal

Any file. Any storage. One gateway.

A .NET API for local, temporary and in-memory storage. Stream files between roots, preview one-way synchronization, and verify backups with SHA-256.

CI MIT Support development

Українська

The project targets .NET 8–11. The installation command applies after publication.

dotnet add package Sunmeat.Portal --version 1.0.0

Quick start

The example syncs a file, creates and verifies a backup, and restores it into a new storage.

using Sunmeat.Portal;

await using var local = Portal.Temporary();
await using var archive = Portal.Temporary();
await using var workspace = Portal.Memory();

await local.WriteTextAsync("docs/hello.txt", "Hello, Portal!");
var plan = await StorageSync.PreviewAsync(local, workspace);
await StorageSync.ApplyAsync(plan);

var snapshot = await StorageBackup.CreateAsync(workspace, archive);
await StorageBackup.VerifyAsync(archive, snapshot);

await using var restored = Portal.Memory();
await StorageBackup.RestoreAsync(archive, snapshot, restored);
var text = await restored.ReadTextAsync("docs/hello.txt");
Console.WriteLine(text);
return text == "Hello, Portal!" ? 0 : 1;

Provider compatibility

Storage Read streams No overwrite by default Directories Native move
Local Yes Yes Yes Yes
Temporary Yes Yes Yes Yes
Memory Yes Yes Yes —
Read-only wrapper Same as backing provider — Listing —
HTTPS Yes — — —
  • Portal.Local(root), Portal.Temporary(), and Portal.Memory() create independent stores. A temporary store cleans up its own directory on DisposeAsync.
  • The caller owns streams returned by OpenReadAsync. WriteAsync reads from the current position and leaves the caller’s stream open. Use those APIs or TransferAsync for large files.
  • Text and byte reads are buffered with a 16 MiB default limit. WriteJsonAsync and ReadJsonAsync take a JsonTypeInfo<T>.
  • SearchAsync matches file suffixes, Sha256Async hashes streams, and FindDuplicatesAsync groups files by length and hash.
  • StorageSync.PreviewAsync reads both stores. ApplyAsync copies missing files, creates directories, and reports conflicts. Use skipConflicts: true to copy the non-conflicting entries.
  • StorageBackup publishes the manifest last. Restore checks bytes and destination conflicts. Set overwrite: true to replace an existing file.
  • MountTable maps prefixes to named stores. Register IPortalStorage through your container’s factory for dependency injection.
  • Portal.Http(baseUri) streams individual HTTPS files without following redirects. LocalStorage.WatchAsync provides local change notifications.

Architecture, guarantees and limits Security policy

FTP and FTPS

Install Sunmeat.Portal.Ftp for FTP, explicit and implicit FTPS. The adapter uses a separate package and defaults to certificate-validated FTPS. See the FTP provider guide for writable roots, usage, and protocol limits.

Build

dotnet run --project examples/QuickStart -c Release
dotnet pack src/Sunmeat.Portal/Sunmeat.Portal.csproj -c Release -o artifacts

Run the local CLI from the repository with dotnet run --project tools/Portal.Cli -- --help. It supports listing, hashing, copying, sync previews, and backup creation, verification and restoration.

Sunmeat ecosystem

Prism · Pulse · Guard · Diff · Morph · Forge · Lens · Signal · Vault · Nexus


❤️ Support the project

Sunmeat.Portal is free, open-source software created and maintained by an independent developer.

If Portal saves you time, simplifies file management, or helps you build reliable storage solutions, consider supporting its continued development.

Building and maintaining free developer tools takes time, effort, curiosity, and resources.

Your support helps fund:

  • New storage providers and cloud integrations.
  • Reliable file transfers and synchronization.
  • Backup and recovery improvements.
  • Security improvements and automated tests.
  • Performance optimizations.
  • Documentation and practical examples.
  • Cloud infrastructure and storage testing costs.
  • Long-term maintenance and platform compatibility.
  • Development tools and AI-assisted development subscriptions, including ChatGPT.
  • New open-source .NET libraries for the community.

Every contribution, regardless of its size, makes a difference.

Even a small donation can help turn the next idea into another free tool for developers.

If this library saved you an hour, consider helping the developer create the next one.

Support development

Patreon Monobank

Financial support is entirely optional. All library features remain free and open source.

External storage providers may charge separately for their services.

You can also support the project by starring the repository, reporting issues, contributing code, or sharing Portal with other developers.

Star on GitHub Developer website


Built with curiosity. Shared with the community.

Copyright © 2026 Oleksandr Zahoruiko · sunmeat.dev

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed.  net11.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net10.0

    • No dependencies.
  • net11.0

    • No dependencies.
  • net8.0

    • No dependencies.
  • net9.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.0 50 12/3/2026