Fix #16: mouse tab click uses calculated positions instead of hardcod… #31
This file contains hidden or 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
| name: Build | |
| on: | |
| push: | |
| tags: ['v*'] | |
| branches: ['**'] | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| build: | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: x86_64-pc-windows-msvc,aarch64-pc-windows-msvc | |
| - name: Cache cargo | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.cargo/registry | |
| ~/.cargo/git | |
| target | |
| key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Install GitVersion | |
| uses: gittools/actions/gitversion/setup@v4 | |
| with: | |
| versionSpec: '6.4.x' | |
| - name: GitVersion | |
| uses: gittools/actions/gitversion/execute@v4 | |
| id: gitversion | |
| - name: Set version | |
| shell: pwsh | |
| run: | | |
| $version = '${{ steps.gitversion.outputs.semVer }}' | |
| Write-Host "Version: $version" | |
| echo "VERSION=$version" >> $env:GITHUB_ENV | |
| - name: Build x64 | |
| run: cargo build --release --target x86_64-pc-windows-msvc | |
| - name: Build ARM64 | |
| run: cargo build --release --target aarch64-pc-windows-msvc | |
| - name: Azure Login | |
| if: startsWith(github.ref, 'refs/tags/') | |
| uses: azure/login@v2 | |
| with: | |
| creds: '{"clientId":"${{ secrets.AZURE_CLIENT_ID }}","clientSecret":"${{ secrets.AZURE_CLIENT_SECRET }}","subscriptionId":"${{ secrets.AZURE_SUBSCRIPTION_ID }}","tenantId":"${{ secrets.AZURE_TENANT_ID }}"}' | |
| - name: Sign executables with Trusted Signing | |
| if: startsWith(github.ref, 'refs/tags/') | |
| uses: azure/trusted-signing-action@v1 | |
| with: | |
| azure-tenant-id: ${{ secrets.AZURE_TENANT_ID }} | |
| azure-client-id: ${{ secrets.AZURE_CLIENT_ID }} | |
| azure-client-secret: ${{ secrets.AZURE_CLIENT_SECRET }} | |
| endpoint: https://wus2.codesigning.azure.net/ | |
| signing-account-name: hanselman | |
| certificate-profile-name: WindowsEdgeLight | |
| files-folder: ${{ github.workspace }} | |
| files-folder-filter: exe | |
| files-folder-recurse: true | |
| file-digest: SHA256 | |
| timestamp-rfc3161: http://timestamp.acs.microsoft.com | |
| timestamp-digest: SHA256 | |
| - name: Prepare artifacts | |
| shell: pwsh | |
| run: | | |
| New-Item -ItemType Directory -Path artifacts -Force | |
| Copy-Item "target/x86_64-pc-windows-msvc/release/winget-tui.exe" -Destination "artifacts/winget-tui-x64.exe" | |
| Copy-Item "target/aarch64-pc-windows-msvc/release/winget-tui.exe" -Destination "artifacts/winget-tui-arm64.exe" | |
| - name: Upload artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: winget-tui-${{ env.VERSION }} | |
| path: artifacts/*.exe | |
| release: | |
| runs-on: ubuntu-latest | |
| needs: [build] | |
| if: startsWith(github.ref, 'refs/tags/') | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Download artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| path: artifacts/ | |
| merge-multiple: true | |
| - name: Create Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| files: artifacts/*.exe | |
| generate_release_notes: true | |
| body: | | |
| ## winget-tui ${{ github.ref_name }} | |
| A terminal UI for Windows Package Manager (winget). | |
| ### 📦 Downloads | |
| | File | Platform | | |
| |------|----------| | |
| | `winget-tui-x64.exe` | Windows x64 | | |
| | `winget-tui-arm64.exe` | Windows ARM64 | | |
| ### Usage | |
| Download the executable for your platform and run it. No installation required. | |
| append_body: true | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |