feat(tui): add mouse interaction and click handling (#6) #7
Workflow file for this run
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: Release | |
| on: | |
| push: | |
| tags: | |
| - 'v[0-9]+.[0-9]+.[0-9]+' | |
| jobs: | |
| release: | |
| name: Release (${{ matrix.target }}) | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| target: x86_64-unknown-linux-gnu | |
| - os: macos-latest | |
| target: x86_64-apple-darwin | |
| - os: macos-latest | |
| target: aarch64-apple-darwin | |
| - os: windows-latest | |
| target: x86_64-pc-windows-msvc | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: ${{ matrix.target }} | |
| - name: Cache Rust dependencies | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Build release | |
| run: cargo build --release --target ${{ matrix.target }} | |
| - name: Prepare artifact | |
| shell: bash | |
| run: | | |
| mkdir -p artifacts | |
| if [[ "${{ matrix.os }}" == "windows-latest" ]]; then | |
| cp "target/${{ matrix.target }}/release/cryptoscope.exe" "artifacts/cryptoscope-${{ matrix.target }}.exe" | |
| else | |
| cp "target/${{ matrix.target }}/release/cryptoscope" "artifacts/cryptoscope-${{ matrix.target }}" | |
| fi | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: cryptoscope-${{ matrix.target }} | |
| path: artifacts/ | |
| retention-days: 5 | |
| publish-release: | |
| name: Publish GitHub Release | |
| needs: release | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Download artifacts | |
| uses: actions/download-artifact@v8 | |
| with: | |
| path: artifacts/ | |
| - name: Generate changelog | |
| id: changelog | |
| run: | | |
| CURRENT_TAG="${{ github.ref_name }}" | |
| PREVIOUS_TAG=$(git tag --sort=-v:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+$' | grep -A1 "^${CURRENT_TAG}$" | tail -n1) | |
| if [ "$PREVIOUS_TAG" = "$CURRENT_TAG" ] || [ -z "$PREVIOUS_TAG" ]; then | |
| CHANGELOG=$(git log --pretty=format:"- %s (%h)" --max-count=20) | |
| else | |
| CHANGELOG=$(git log --pretty=format:"- %s (%h)" "${PREVIOUS_TAG}..HEAD") | |
| fi | |
| echo "changelog<<EOF" >> $GITHUB_OUTPUT | |
| echo "$CHANGELOG" >> $GITHUB_OUTPUT | |
| echo "EOF" >> $GITHUB_OUTPUT | |
| - name: Publish release | |
| uses: softprops/action-gh-release@v3 | |
| with: | |
| files: artifacts/**/* | |
| body: ${{ steps.changelog.outputs.changelog }} | |
| generate_release_notes: false |