From dbee6b8cb9e48973c7942a063ce85853ead346f1 Mon Sep 17 00:00:00 2001 From: Rob Reynolds Date: Thu, 28 Apr 2016 13:33:01 -0500 Subject: [PATCH] (GH-713) Rename Get-ProcessorBits Get-OSArchitectureWidth Keep around the alias for Get-ProcessorBits though. --- src/chocolatey.resources/chocolatey.resources.csproj | 2 +- ...-ProcessorBits.ps1 => Get-OSArchitectureWidth.ps1} | 11 ++++++++--- 2 files changed, 9 insertions(+), 4 deletions(-) rename src/chocolatey.resources/helpers/functions/{Get-ProcessorBits.ps1 => Get-OSArchitectureWidth.ps1} (80%) diff --git a/src/chocolatey.resources/chocolatey.resources.csproj b/src/chocolatey.resources/chocolatey.resources.csproj index 43c4e25c67..1666e8da1c 100644 --- a/src/chocolatey.resources/chocolatey.resources.csproj +++ b/src/chocolatey.resources/chocolatey.resources.csproj @@ -48,7 +48,7 @@ - + diff --git a/src/chocolatey.resources/helpers/functions/Get-ProcessorBits.ps1 b/src/chocolatey.resources/helpers/functions/Get-OSArchitectureWidth.ps1 similarity index 80% rename from src/chocolatey.resources/helpers/functions/Get-ProcessorBits.ps1 rename to src/chocolatey.resources/helpers/functions/Get-OSArchitectureWidth.ps1 index 098e163f1c..6795be562e 100644 --- a/src/chocolatey.resources/helpers/functions/Get-ProcessorBits.ps1 +++ b/src/chocolatey.resources/helpers/functions/Get-OSArchitectureWidth.ps1 @@ -12,10 +12,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -function Get-ProcessorBits { +function Get-OSArchitectureWidth { <# .SYNOPSIS -Get the system architecture address width. +Get the operating system architecture address width. .DESCRIPTION This will return the system architecture address width (probably 32 or @@ -26,6 +26,9 @@ of {`32`|`64`}. When your installation script has to know what architecture it is run on, this simple function comes in handy. +If you need compatibility with pre 0.9.10, please use the alias +`Get-ProcessorBits`. + .INPUTS None @@ -40,7 +43,7 @@ depending on wether or not the bit width matches. param( $compare ) - Write-Debug "Running 'Get-ProcessorBits'" + Write-Debug "Running 'Get-OSArchitectureWidth'" $bits = 64 if ([System.IntPtr]::Size -eq 4) { @@ -56,3 +59,5 @@ param( return $bits } } + +Set-Alias Get-ProcessorBits Get-OSArchitectureWidth