Skip to content

Commit

Permalink
CI: Configure LibPQ for actions
Browse files Browse the repository at this point in the history
  • Loading branch information
imsk17 committed Mar 16, 2024
1 parent 69c3ced commit 0d8318d
Showing 1 changed file with 25 additions and 4 deletions.
29 changes: 25 additions & 4 deletions .github/workflows/Build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,27 @@ jobs:
target: ${{ matrix.target }}
override: true

- name: Install postgres (Windows)
if: matrix.os == 'windows-latest'
shell: bash
run: |
choco install postgresql12 --force --params '/Password:root'
echo "C:\Program Files\PostgreSQL\12\bin" >> $GITHUB_PATH
echo "C:\Program Files\PostgreSQL\12\lib" >> $GITHUB_PATH
echo "PQ_LIB_DIR=C:\Program Files\PostgreSQL\12\lib" >> $GITHUB_ENV
- name: Install postgres (MacOS M1)
if: matrix.os == 'macos-14' || matrix.os == 'macos-latest'
run: |
brew install postgresql
brew services start postgresql@14
- name: Install postgres (Linux)
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libpq-dev postgresql
- name: Build
run: cargo build --release --target ${{ matrix.target }}

Expand All @@ -52,19 +73,19 @@ jobs:
# Zip artifacts for Windows
if [ "${{ matrix.os }}" == "windows-latest" ]; then
7z a quicssh-${{ matrix.os }}.zip artifacts/
7z a formula-${{ matrix.os }}.zip artifacts/
else
tar -czvf quicssh-${{ matrix.os }}.tar.gz artifacts/
tar -czvf formula-${{ matrix.os }}.tar.gz artifacts/
fi
shell: bash

- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}
path: ./quicssh*
path: ./formula*
env:
PROJECT_NAME: quicssh
PROJECT_NAME: formula

release:
name: Release
Expand Down

0 comments on commit 0d8318d

Please sign in to comment.