-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add NuGet package README and metadata.
- Loading branch information
Showing
6 changed files
with
61 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# NGuid | ||
|
||
[![Continuous Integration](https://github.com/bgrainger/NGuid/actions/workflows/ci.yaml/badge.svg)](https://github.com/bgrainger/NGuid/actions/workflows/ci.yaml) | ||
|
||
## About | ||
|
||
NGuid provides efficient creation of name-based GUIDs according to [RFC4122](https://datatracker.ietf.org/doc/html/rfc4122): | ||
|
||
* Version 3 - created from an MD5 hash of a name | ||
* Version 5 (default) - created from a SHA1 hash of a name | ||
|
||
## Usage | ||
|
||
```csharp | ||
// returns a "Version 5" UUID by default: {74738ff5-5367-5958-9aee-98fffdcd1876} | ||
var guid = GuidHelpers.CreateFromName(GuidHelpers.DnsNamespace, "www.example.org"u8); | ||
|
||
// can also create "Version 3": {0012416f-9eec-3ed4-a8b0-3bceecde1cd9} | ||
var guidv3 = GuidHelpers.CreateFromName(GuidHelpers.DnsNamespace, "www.example.org"u8, version: 3); | ||
``` | ||
|
||
## License | ||
|
||
[MIT](https://github.com/bgrainger/NGuid/blob/master/LICENSE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Release Notes | ||
|
||
## 0.1.0 | ||
|
||
* First public release. | ||
* Provide `GuidHelpers.CreateFromName` to create Version 3 and Version 5 UUIDs. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
## NGuid | ||
|
||
NGuid provides efficient creation of name-based GUIDs according to [RFC4122](https://datatracker.ietf.org/doc/html/rfc4122): | ||
|
||
* Version 3 - created from an MD5 hash of a name | ||
* Version 5 (default) - created from a SHA1 hash of a name | ||
|
||
## Usage | ||
|
||
```csharp | ||
// returns a "Version 5" UUID by default: {74738ff5-5367-5958-9aee-98fffdcd1876} | ||
var guid = GuidHelpers.CreateFromName(GuidHelpers.DnsNamespace, "www.example.org"u8); | ||
|
||
// can also create "Version 3": {0012416f-9eec-3ed4-a8b0-3bceecde1cd9} | ||
var guidv3 = GuidHelpers.CreateFromName(GuidHelpers.DnsNamespace, "www.example.org"u8, version: 3); | ||
``` |