Skip to content

Commit da25039

Browse files
authored
Merge pull request #135 from microsoft/stuartpa/choco
Choco (Windows) release package
2 parents 27f0f7f + f28ab98 commit da25039

File tree

5 files changed

+114
-1
lines changed

5 files changed

+114
-1
lines changed

release/linux/deb/prepare-rules.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ sqlcmd (${CLI_VERSION}-${CLI_VERSION_REVISION:=1}) stable; urgency=low
4444
4545
* Debian package release.
4646
47-
-- sqlcmd tools team <dpgswdist@microsoft.com@microsoft.com> $(date -R)
47+
-- sqlcmd tools team <dpgswdist@microsoft.com> $(date -R)
4848
4949
EOM
5050

release/windows/choco/sqlcmd.nuspec

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!-- Do not remove this test for UTF-8: if “Ω” doesn’t appear as greek uppercase omega letter enclosed in quotation marks, you should use an editor that supports UTF-8, not this one. -->
3+
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
4+
<metadata>
5+
<id>sqlcmd</id>
6+
<version>0.8.1</version>
7+
<title>sqlcmd (Install)</title>
8+
<authors>Microsoft</authors>
9+
<projectUrl>https://docs.microsoft.com/en-us/sql/tools/go-sqlcmd-utility</projectUrl>
10+
<iconUrl>https://github.com/microsoft/go-sqlcmd/blob/main/release/windows/msi/resources/go-sqlcmd_256.png</iconUrl>
11+
<copyright>Copyright (c) Microsoft Corporation</copyright>
12+
<licenseUrl>https://github.com/microsoft/go-sqlcmd/blob/main/LICENSE</licenseUrl>
13+
<requireLicenseAcceptance>false</requireLicenseAcceptance>
14+
<projectSourceUrl>https://github.com/microsoft/go-sqlcmd</projectSourceUrl>
15+
<packageSourceUrl>https://github.com/microsoft/go-sqlcmd/tree/main/release/windows/choco</packageSourceUrl>
16+
<docsUrl>https://docs.microsoft.com/en-us/sql/tools/go-sqlcmd-utility</docsUrl>
17+
<bugTrackerUrl>https://github.com/microsoft/go-sqlcmd/issues</bugTrackerUrl>
18+
<tags>sqlcmd mssql sqlserver</tags>
19+
<summary>sqlcmd CLI for Microsoft SQL Server and Azure SQL</summary>
20+
<description>sqlcmd is a multi-platform command line experience for Microsoft SQL Server and Azure SQL</description>
21+
<releaseNotes>https://github.com/microsoft/go-sqlcmd/releases/tag/v0.8.1</releaseNotes>
22+
</metadata>
23+
<files>
24+
<file src="tools\**" target="tools" />
25+
</files>
26+
</package>
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
From: https://github.com/microsoft/go-sqlcmd/blob/main/LICENSE
2+
3+
LICENSE
4+
5+
MIT License
6+
7+
Copyright (c) Microsoft Corporation.
8+
9+
Permission is hereby granted, free of charge, to any person obtaining a copy
10+
of this software and associated documentation files (the "Software"), to deal
11+
in the Software without restriction, including without limitation the rights
12+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
13+
copies of the Software, and to permit persons to whom the Software is
14+
furnished to do so, subject to the following conditions:
15+
16+
The above copyright notice and this permission notice shall be included in all
17+
copies or substantial portions of the Software.
18+
19+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
24+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
25+
SOFTWARE
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+

2+
Note: Include this file if including binaries you have the right to distribute.
3+
Otherwise delete. this file. If you are the software author, you can change this
4+
mention you are the author of the software.
5+
6+
===DELETE ABOVE THIS LINE AND THIS LINE===
7+
8+
VERIFICATION
9+
Verification is intended to assist the Chocolatey moderators and community
10+
in verifying that this package's contents are trustworthy.
11+
12+
Download .msi from Microsoft Download Center
13+
https://download.microsoft.com/download/d/4/4/d4403a51-2ab7-4ea8-b850-d2710c5e1323/sqlcmd_0.8.1-1.msi
14+
15+
Run checksum -t sha256 -f sqlcmd_0.8.1-1.msi
16+
17+
We are the software vendor (Microsoft)
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
$ErrorActionPreference = 'Stop';
2+
3+
$toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)"
4+
$url = '{{DownloadUrl}}'
5+
$url64 = 'https://download.microsoft.com/download/d/4/4/d4403a51-2ab7-4ea8-b850-d2710c5e1323/sqlcmd_0.8.1-1.msi'
6+
7+
$packageArgs = @{
8+
packageName = $env:ChocolateyPackageName
9+
unzipLocation = $toolsDir
10+
fileType = 'MSI'
11+
url = $url
12+
url64bit = $url64
13+
14+
softwareName = 'sqlcmd*'
15+
16+
checksum = '{{Checksum}}'
17+
checksumType = '{{ChecksumType}}'
18+
checksum64 = '03587762932D5A66ACFE15D306FE14645D53BC61162B4DA0D9AF29B4A8A1550D'
19+
checksumType64= 'sha256'
20+
21+
silentArgs = "/qn /norestart /l*v `"$($env:TEMP)\$($packageName).$($env:chocolateyPackageVersion).MsiInstall.log`""
22+
validExitCodes= @(0, 3010, 1641)
23+
}
24+
25+
Install-ChocolateyPackage @packageArgs
26+
27+
28+
29+
30+
31+
32+
33+
34+
35+
36+
37+
38+
39+
40+
41+
42+
43+
44+
45+

0 commit comments

Comments
 (0)