Skip to content

Commit

Permalink
Create crystaldiskinfo install and portable versions
Browse files Browse the repository at this point in the history
Create crystaldiskinfo install and portable versions
  • Loading branch information
aronovgj committed Oct 31, 2016
1 parent 248fd3f commit 6f3296c
Show file tree
Hide file tree
Showing 11 changed files with 101 additions and 31 deletions.
26 changes: 26 additions & 0 deletions crystaldiskinfo.install/crystaldiskinfo.install.nuspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>{{PackageName}}</id>
<title>CrystalDiskInfo (Install)</title>
<version>{{PackageVersion}}</version>
<authors>hiyohiyo</authors>
<owners>doc</owners>
<summary>
CrystalDiskInfo is a HDD/SSD utility software which shows the health status much more clearly than similar tools.
</summary>
<description>
CrystalDiskInfo is a HDD/SSD utility software which shows the health status much more clearly than similar tools.
The "Function / Graph" is especially interesting for the "Reallocated Sectors Count".
If it increases over time or is very high already, the hard drive may need to be replaced.
</description>
<projectUrl>http://crystalmark.info/software/CrystalDiskInfo/index-e.html</projectUrl>
<tags>disk diagnostic hdd ssd admin</tags>
<copyright></copyright>
<licenseUrl>http://crystalmark.info/software/CrystalDiskInfo/manual-en/License.html</licenseUrl>
<packageSourceUrl>https://github.com/aronovgj/choco-auto</packageSourceUrl>

<requireLicenseAcceptance>false</requireLicenseAcceptance>
<iconUrl>https://cdn.rawgit.com/aronovgj/chocolatey/master/icons/{{PackageName}}.png</iconUrl>
</metadata>
</package>
15 changes: 15 additions & 0 deletions crystaldiskinfo.install/tools/chocolateyInstall.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
$packageName = '{{PackageName}}'
$url = '{{DownloadUrl}}'

$packageArgs = @{
packageName = $packageName
fileType = 'exe'
url = $url
silentArgs = '/VERYSILENT /SUPPRESSMSGBOXES /NORESTART /SP-'
softwareName = $packageName
checksum = '{{Checksum}}'
checksumType = 'sha256'
}

Install-ChocolateyPackage @packageArgs

26 changes: 26 additions & 0 deletions crystaldiskinfo.portable/crystaldiskinfo.portable.nuspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>{{PackageName}}</id>
<title>CrystalDiskInfo (Portable)</title>
<version>{{PackageVersion}}</version>
<authors>hiyohiyo</authors>
<owners>doc</owners>
<summary>
CrystalDiskInfo is a HDD/SSD utility software which shows the health status much more clearly than similar tools.
</summary>
<description>
CrystalDiskInfo is a HDD/SSD utility software which shows the health status much more clearly than similar tools.
The "Function / Graph" is especially interesting for the "Reallocated Sectors Count".
If it increases over time or is very high already, the hard drive may need to be replaced.
</description>
<projectUrl>http://crystalmark.info/software/CrystalDiskInfo/index-e.html</projectUrl>
<tags>disk diagnostic hdd ssd</tags>
<copyright></copyright>
<licenseUrl>http://crystalmark.info/software/CrystalDiskInfo/manual-en/License.html</licenseUrl>
<packageSourceUrl>https://github.com/aronovgj/choco-auto</packageSourceUrl>

<requireLicenseAcceptance>false</requireLicenseAcceptance>
<iconUrl>https://cdn.rawgit.com/aronovgj/chocolatey/master/icons/{{PackageName}}.png</iconUrl>
</metadata>
</package>
File renamed without changes.
30 changes: 30 additions & 0 deletions crystaldiskinfo.portable/tools/chocolateyInstall.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
$packageName = '{{PackageName}}'
$url = '{{DownloadUrl}}'
$fileName32 = "DiskInfo32.exe"
$fileName64 = "DiskInfo64.exe"
$linkName = "CrystalDiskInfo.lnk"
$toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)"

$packageArgs = @{
packageName = $packageName
unzipLocation = $toolsDir
fileType = 'zip'
url = $url
softwareName = $packageName
checksum = '{{Checksum}}'
checksumType = 'sha256'
}

Install-ChocolateyZipPackage @packageArgs

#install start menu shortcut
$fileName = $fileName32
$is64bit = Get-ProcessorBits 64
if ($is64bit) {
$fileName = $fileName64
}

$programs = [environment]::GetFolderPath([environment+specialfolder]::Programs)
$shortcutFilePath = Join-Path $programs $linkName
$targetPath = Join-Path $toolsDir $fileName
Install-ChocolateyShortcut -shortcutFilePath $shortcutFilePath -targetPath $targetPath
4 changes: 3 additions & 1 deletion crystaldiskinfo/crystaldiskinfo.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ If it increases over time or is very high already, the hard drive may need to be
<copyright></copyright>
<licenseUrl>http://crystalmark.info/software/CrystalDiskInfo/manual-en/License.html</licenseUrl>
<packageSourceUrl>https://github.com/aronovgj/choco-auto</packageSourceUrl>

<dependencies>
<dependency id="crystaldiskinfo.portable" version="{{PackageVersion}}" />
</dependencies>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<iconUrl>https://cdn.rawgit.com/aronovgj/chocolatey/master/icons/{{PackageName}}.png</iconUrl>
</metadata>
Expand Down
31 changes: 1 addition & 30 deletions crystaldiskinfo/tools/chocolateyInstall.ps1
Original file line number Diff line number Diff line change
@@ -1,30 +1 @@
$packageName = '{{PackageName}}'
$url = '{{DownloadUrl}}'
$fileName32 = "DiskInfo32.exe"
$fileName64 = "DiskInfo64.exe"
$linkName = "CrystalDiskInfo.lnk"
$toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)"

$packageArgs = @{
packageName = $packageName
unzipLocation = $toolsDir
fileType = 'zip'
url = $url
softwareName = $packageName
checksum = '{{Checksum}}'
checksumType = 'sha256'
}

Install-ChocolateyZipPackage @packageArgs

#install start menu shortcut
$fileName = $fileName32
$is64bit = Get-ProcessorBits 64
if ($is64bit) {
$fileName = $fileName64
}

$programs = [environment]::GetFolderPath([environment+specialfolder]::Programs)
$shortcutFilePath = Join-Path $programs $linkName
$targetPath = Join-Path $toolsDir $fileName
Install-ChocolateyShortcut -shortcutFilePath $shortcutFilePath -targetPath $targetPath
#Install-VirtualPackage 'crystaldiskinfo.install' 'crystaldiskinfo.portable'

0 comments on commit 6f3296c

Please sign in to comment.