Skip to content

Commit

Permalink
(chocolateyGH-713) Rename Get-ProcessorBits Get-OSArchitectureWidth
Browse files Browse the repository at this point in the history
Keep around the alias for Get-ProcessorBits though.
  • Loading branch information
ferventcoder committed Apr 29, 2016
1 parent c7c6091 commit 8bc6f5a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/chocolatey.resources/chocolatey.resources.csproj
Expand Up @@ -48,7 +48,7 @@
<EmbeddedResource Include="helpers\functions\Get-ChocolateyUnzip.ps1" />
<EmbeddedResource Include="helpers\functions\Get-ChocolateyWebFile.ps1" />
<EmbeddedResource Include="helpers\functions\Get-FtpFile.ps1" />
<EmbeddedResource Include="helpers\functions\Get-ProcessorBits.ps1" />
<EmbeddedResource Include="helpers\functions\Get-OSArchitectureWidth.ps1" />
<EmbeddedResource Include="helpers\functions\Get-UACEnabled.ps1" />
<EmbeddedResource Include="helpers\functions\Get-VirusCheckValid.ps1" />
<EmbeddedResource Include="helpers\functions\Get-WebFile.ps1" />
Expand Down
Expand Up @@ -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
Expand All @@ -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
Expand All @@ -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) {
Expand All @@ -56,3 +59,5 @@ param(
return $bits
}
}

Set-Alias Get-ProcessorBits Get-OSArchitectureWidth

0 comments on commit 8bc6f5a

Please sign in to comment.