Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 20 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,11 @@
# GUID

A PowerShell module that extends the native capabilities for working with Globally Unique Identifiers (GUIDs).

## Prerequisites

This module uses the following external resources:
- The [PSModule framework](https://github.com/PSModule) for building, testing, and publishing the module.
It adds convenient commands to validate whether a string is a GUID and to extract GUIDs embedded in text.

## Installation

To install the module from the PowerShell Gallery, run the following commands:
Install the module from the PowerShell Gallery:

```powershell
Install-PSResource -Name GUID
Expand All @@ -18,53 +14,39 @@ Import-Module -Name GUID

## Usage

Here are some typical use cases for the GUID module.
### Example: Test if a string is a GUID

### Example 1: Test if a string is a GUID

Check if a string is a valid GUID using:
Validate whether a string is a well-formed GUID. The command accepts pipeline input and returns a boolean.

```powershell
Test-Guid -Guid 'd85b1407-351d-4694-9392-03acc5870eb1'
Test-Guid -String 'd85b1407-351d-4694-9392-03acc5870eb1'
'd85b1407-351d-4694-9392-03acc5870eb1' | Test-Guid
'd85b1407-351d-4694-9392-03acc5870eb1' | IsGuid
```

This command returns `True` if the provided string is a valid GUID; otherwise, it returns `False`.

### Example 2: Find a GUID in a string

Extract a GUID from a string using:

```powershell
Search-Guid -Text "The GUID is d85b1407-351d-4694-9392-03acc5870eb1"
```text
True
True
```

This command returns the GUID found in the provided string.

### Find More Examples
### Example: Find a GUID in a string

For additional usage examples, please refer to the [examples](examples) folder. You can also list all available commands with:
Extract the GUID embedded in a longer string. The command returns the matched GUID value.

```powershell
Get-Command -Module GUID
'The ID is d85b1407-351d-4694-9392-03acc5870eb1' | Search-Guid
```

And view detailed help for each command (for instance, for New-GuidPlus) by running:

```powershell
Get-Help -Examples <command>
```text
d85b1407-351d-4694-9392-03acc5870eb1
```

## Contributing

Contributions are welcome—whether you're reporting an issue, suggesting improvements, or submitting new code!
## Documentation

### For Users
Documentation is published at [psmodule.io/GUID](https://psmodule.io/GUID/).

If you encounter any bugs, unexpected behavior, or missing functionality, please open an issue on this repository. Your feedback is valuable.
Discover the available commands and browse their help from the terminal:

### For Developers

If you'd like to contribute code or enhancements, please review the [Contribution Guidelines](CONTRIBUTING.md) first. You can start by addressing
an existing issue or proposing a new feature.
```powershell
Get-Command -Module GUID
Get-Help -Name Test-Guid -Examples
```
Loading