< Back
Resolve-CFullPath
Post
NAME Resolve-CFullPath
SYNOPSIS
Converts a relative path to an absolute path.
SYNTAX
Resolve-CFullPath [-Path] <String> [<CommonParameters>]
DESCRIPTION
Unlike `Resolve-Path`, this function does not check whether the path exists. It just converts relative paths to
absolute paths.
Unrooted paths (e.g. `..\\..\\See\\I\\Do\\Not\\Have\\A\\Root`) are first joined with the current directory (as returned by
`Get-Location`).
PARAMETERS
-Path <String>
The path to resolve. Must be rooted, i.e. have a drive at the beginning.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Resolve-CFullPath -Path 'C:\\Projects\\Carbon\\Test\\..\\Carbon\\FileSystem.ps1'
Returns `C:\\Projects\\Carbon\\Carbon\\FileSystem.ps1`.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Resolve-CFullPath -Path 'C:\\Projects\\Carbon\\..\\I\\Do\\Not\\Exist'
Returns `C:\\Projects\\I\\Do\\Not\\Exist`.
-------------------------- EXAMPLE 3 --------------------------
PS C:\\>Resolve-CFullPath -Path ..\\..\\Foo\\..\\Bar
Because the `Path` isn't rooted, joins `Path` with the current directory (as returned by `Get-Location`), and
returns the full path. If the current directory is `C:\\Projects\\Carbon`, returns `C:\\Bar`.
RELATED LINKS
SYNOPSIS
Converts a relative path to an absolute path.
SYNTAX
Resolve-CFullPath [-Path] <String> [<CommonParameters>]
DESCRIPTION
Unlike `Resolve-Path`, this function does not check whether the path exists. It just converts relative paths to
absolute paths.
Unrooted paths (e.g. `..\\..\\See\\I\\Do\\Not\\Have\\A\\Root`) are first joined with the current directory (as returned by
`Get-Location`).
PARAMETERS
-Path <String>
The path to resolve. Must be rooted, i.e. have a drive at the beginning.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Resolve-CFullPath -Path 'C:\\Projects\\Carbon\\Test\\..\\Carbon\\FileSystem.ps1'
Returns `C:\\Projects\\Carbon\\Carbon\\FileSystem.ps1`.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Resolve-CFullPath -Path 'C:\\Projects\\Carbon\\..\\I\\Do\\Not\\Exist'
Returns `C:\\Projects\\I\\Do\\Not\\Exist`.
-------------------------- EXAMPLE 3 --------------------------
PS C:\\>Resolve-CFullPath -Path ..\\..\\Foo\\..\\Bar
Because the `Path` isn't rooted, joins `Path` with the current directory (as returned by `Get-Location`), and
returns the full path. If the current directory is `C:\\Projects\\Carbon`, returns `C:\\Bar`.
RELATED LINKS