GUI: Extend selection with shift-click. #12 #53
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
| on: push | |
| name: Build, Lint, and Test | |
| jobs: | |
| clippy: | |
| name: Run Clippy Lints | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Install FLTK dependencies | |
| run: sudo apt install -y libx11-dev libxext-dev libxft-dev libxinerama-dev libxcursor-dev libxrender-dev libxfixes-dev libpango1.0-dev libgl1-mesa-dev libglu1-mesa-dev libwayland-dev libxkbcommon-dev libdbus-1-dev | |
| - name: Set up Rust | |
| uses: actions-rs/toolchain@v1 | |
| with: | |
| toolchain: stable | |
| override: true | |
| - name: Install Clippy | |
| run: rustup component add clippy | |
| - name: Cache cargo registry | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.cargo/registry | |
| key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Cache cargo index | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.cargo/git | |
| key: ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Run Clippy | |
| run: cargo clippy --all-targets --all-features -- -D warnings | |
| tests: | |
| name: Run Tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Install FLTK dependencies | |
| run: sudo apt install -y libx11-dev libxext-dev libxft-dev libxinerama-dev libxcursor-dev libxrender-dev libxfixes-dev libpango1.0-dev libgl1-mesa-dev libglu1-mesa-dev libwayland-dev libxkbcommon-dev libdbus-1-dev | |
| - name: Set up Rust | |
| uses: actions-rs/toolchain@v1 | |
| with: | |
| toolchain: stable | |
| override: true | |
| - name: Cache cargo registry | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.cargo/registry | |
| key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Cache cargo index | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.cargo/git | |
| key: ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Run Tests | |
| run: cargo test --all-targets --all-features | |
| build: | |
| name: Build ${{ matrix.platform.name }} (${{ matrix.platform.arch }}) | |
| runs-on: ${{ matrix.platform.runner }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| platform: | |
| # Linux x64 | |
| - name: Linux | |
| runner: ubuntu-latest | |
| arch: x86_64 | |
| target: x86_64-unknown-linux-gnu | |
| deps: sudo apt install -y libx11-dev libxext-dev libxft-dev libxinerama-dev libxcursor-dev libxrender-dev libxfixes-dev libpango1.0-dev libgl1-mesa-dev libglu1-mesa-dev libwayland-dev libxkbcommon-dev libdbus-1-dev | |
| artifact_name: piki-gui-linux-x86_64 | |
| # Linux ARM64 | |
| - name: Linux | |
| runner: ubuntu-24.04-arm | |
| arch: aarch64 | |
| target: aarch64-unknown-linux-gnu | |
| deps: sudo apt install -y libx11-dev libxext-dev libxft-dev libxinerama-dev libxcursor-dev libxrender-dev libxfixes-dev libpango1.0-dev libgl1-mesa-dev libglu1-mesa-dev libwayland-dev libxkbcommon-dev libdbus-1-dev | |
| artifact_name: piki-gui-linux-aarch64 | |
| # macOS x64 (Intel) | |
| - name: macOS | |
| runner: macos-13 | |
| arch: x86_64 | |
| target: x86_64-apple-darwin | |
| deps: echo "No additional dependencies needed for macOS" | |
| artifact_name: piki-gui-macos-x86_64 | |
| # macOS ARM64 (Apple Silicon) | |
| - name: macOS | |
| runner: macos-latest | |
| arch: aarch64 | |
| target: aarch64-apple-darwin | |
| deps: echo "No additional dependencies needed for macOS" | |
| artifact_name: piki-gui-macos-aarch64 | |
| # Windows x64 | |
| - name: Windows | |
| runner: windows-latest | |
| arch: x86_64 | |
| target: x86_64-pc-windows-msvc | |
| deps: echo "No additional dependencies needed for Windows" | |
| artifact_name: piki-gui-windows-x86_64.exe | |
| # Windows ARM64 | |
| - name: Windows | |
| runner: windows-latest | |
| arch: aarch64 | |
| target: aarch64-pc-windows-msvc | |
| deps: echo "No additional dependencies needed for Windows" | |
| artifact_name: piki-gui-windows-aarch64.exe | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Install platform dependencies | |
| run: ${{ matrix.platform.deps }} | |
| - name: Set up Rust | |
| uses: actions-rs/toolchain@v1 | |
| with: | |
| toolchain: stable | |
| override: true | |
| target: ${{ matrix.platform.target }} | |
| - name: Cache cargo registry | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.cargo/registry | |
| key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Cache cargo index | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.cargo/git | |
| key: ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Cache cargo build | |
| uses: actions/cache@v3 | |
| with: | |
| path: target | |
| key: ${{ runner.os }}-${{ matrix.platform.target }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Build release binary | |
| run: cargo build --release --target ${{ matrix.platform.target }} | |
| - name: Prepare artifact (Unix) | |
| if: runner.os != 'Windows' | |
| run: | | |
| mkdir -p artifacts | |
| cp target/${{ matrix.platform.target }}/release/piki-gui artifacts/${{ matrix.platform.artifact_name }} | |
| - name: Prepare artifact (Windows) | |
| if: runner.os == 'Windows' | |
| run: | | |
| mkdir artifacts | |
| cp target/${{ matrix.platform.target }}/release/piki-gui.exe artifacts/${{ matrix.platform.artifact_name }} | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: ${{ matrix.platform.artifact_name }} | |
| path: artifacts/${{ matrix.platform.artifact_name }} | |
| if-no-files-found: error |