-
Notifications
You must be signed in to change notification settings - Fork 161
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add winget action * add comment * Update UpdateWinget.yml * Update UpdateWinget.yml * Update UpdateWinget.yml * Update UpdateWinget.yml * Update UpdateWinget.yml * make testable * remove push test
- Loading branch information
1 parent
30a77d6
commit af71b08
Showing
2 changed files
with
33 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# Publishes the latest MFCMAPI release to the Windows Package Manager (Winget) | ||
# https://github.com/microsoft/winget-create?tab=readme-ov-file | ||
name: Update Winget $(Year:yy).0.$(date:yy)$(DayOfYear)$(rev:.rr) | ||
|
||
on: | ||
workflow_dispatch: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
build: | ||
runs-on: windows-latest | ||
|
||
steps: | ||
- name: '📫🚀 Publish Latest MFCMAPI Release to Winget' | ||
run: | | ||
$wingetPackage = "Microsoft.MFCMAPI" | ||
$gitToken = "${{ secrets.MFCMAPI_WINGET }}" | ||
$github = Invoke-RestMethod -uri "https://api.github.com/repos/Microsoft/MFCMAPI/releases" | ||
$targetRelease = $github | Where-Object { -not $_.draft -and -not $_.prerelease }| Select -First 1 | ||
$ver = $targetRelease.tag_name -ireplace '^v' | ||
# Write-Host $targetRelease | ||
# Write-Host $ver | ||
$installerUserX86Url = $targetRelease | Select -ExpandProperty assets -First 1 | Where-Object -Property name -match 'MFCMAPI.exe' | Select -ExpandProperty browser_download_url | ||
$installerUserX64Url = $targetRelease | Select -ExpandProperty assets -First 1 | Where-Object -Property name -match 'MFCMAPI.x64.exe' | Select -ExpandProperty browser_download_url | ||
# getting latest wingetcreate file | ||
iwr https://aka.ms/wingetcreate/latest -OutFile wingetcreate.exe | ||
.\wingetcreate.exe update $wingetPackage -s -v $ver -u "$installerUserX86Url|user" "$installerUserX64Url|user" -t $gitToken | ||
shell: pwsh |
Submodule mapistub
updated
4 files
+1 −1 | .github/workflows/clang.yml | |
+4 −4 | .github/workflows/codeql.yml | |
+2 −2 | .github/workflows/devskim.yml | |
+2 −2 | .github/workflows/scorecards.yml |