Feat/datetimeoffset #15
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
name: 'Build' | |
env: | |
VERSION: 4.25.0 | |
PACKAGE_SUFFIX: '-pre.3' | |
# PACKAGE_SUFFIX: '' | |
ASM_VERSION: 4.0.0 | |
DOC_INSTANCE: wrs/pq | |
DOC_ARTIFACT: webHelpPQ2-all.zip | |
DOC_ALGOLIA_ARTIFACT: algolia-indexes-PQ.zip | |
DOC_DOCKER_VERSION: 241.15989 | |
# Gives the workflow permissions to clone the repo and create a page deployment | |
permissions: | |
id-token: write | |
pages: write | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
workflow_dispatch: | |
jobs: | |
test: | |
name: Unit Tests | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, windows-latest, macos-latest] | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: | | |
6.0.x | |
8.0.x | |
- name: Setup Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- name: Install Python dependencies | |
run: pip install pyarrow pandas | |
- name: 'test on ${{ matrix.os }}' | |
run: dotnet test src/Parquet.sln -c release | |
build: | |
runs-on: 'ubuntu-latest' | |
name: 'Build NuGet' | |
steps: | |
- run: | | |
echo head_ref: ${{ github.head_ref }} | |
echo run id: ${{ github.run_id }} | |
- uses: actions/checkout@v3 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: | | |
6.0.x | |
8.0.x | |
- name: Build Library | |
run: | | |
envsubst < src/Parquet/Globals.cs > g.tmp && mv g.tmp src/Parquet/Globals.cs | |
cat src/Parquet/Globals.cs | |
dotnet build src/Parquet.sln -c release /p:Version=${{ env.VERSION }}${{ env.PACKAGE_SUFFIX }} /p:FileVersion=$VERSION /p:AssemblyVersion=$ASM_VERSION | |
- name: collect artifacts | |
run: | | |
mkdir artifacts | |
cp src/Parquet/bin/Release/*.nupkg artifacts/ | |
echo "${{ env.VERSION }}" >> artifacts/version.txt | |
cp docs/release-history.md artifacts/ | |
- uses: actions/upload-artifact@v3 | |
name: upload artifacts | |
with: | |
name: bin | |
path: artifacts/* | |
floor-build: | |
runs-on: ubuntu-latest | |
name: 'Build Floor' | |
strategy: | |
matrix: | |
rid: | |
- linux-x64 | |
- win-x64 | |
- osx-x64 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: | | |
8.0.x | |
- name: Build | |
env: | |
LATEST_NET_ONLY: true | |
run: | | |
envsubst < src/Parquet/Globals.cs > g.tmp && mv g.tmp src/Parquet/Globals.cs | |
dotnet restore src/Parquet.Floor/Parquet.Floor.csproj | |
dotnet publish src/Parquet.Floor/Parquet.Floor.csproj -c release -r ${{ matrix.rid }} -o floor-pub/${{ matrix.rid }} /p:Version=${{ env.VERSION }}${{ env.PACKAGE_SUFFIX }} /p:FileVersion=${{ env.VERSION }} /p:AssemblyVersion=${{ env.ASM_VERSION }} | |
mkdir -p floor-dist | |
zip -r -9 -j floor-dist/floor-${{ matrix.rid }}-${{ env.VERSION }}.zip floor-pub/${{ matrix.rid }}/* -x *.pdb *.xml | |
- uses: actions/upload-artifact@v4 | |
name: upload binary | |
if: github.ref == 'refs/heads/master' | |
with: | |
name: floor-${{ matrix.rid }} | |
path: floor-dist/*.zip | |
if-no-files-found: error | |
compression-level: 9 | |
retention-days: 1 | |
wrs-build: | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/master' | |
name: Build Documentation | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Build Writerside docs | |
uses: JetBrains/writerside-github-action@v4 | |
with: | |
instance: ${{ env.DOC_INSTANCE }} | |
artifact: ${{ env.DOC_INSTANCE }} | |
docker-version: ${{ env.DOC_DOCKER_VERSION }} | |
- name: Upload documentation | |
uses: actions/upload-artifact@v4 | |
with: | |
name: docs | |
path: artifacts/*.zip | |
retention-days: 1 | |
wrs-deploy: | |
runs-on: ubuntu-latest | |
needs: [wrs-build, test, build] | |
name: Deploy Documentation | |
steps: | |
- name: ⬇️ Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
name: docs | |
- name: 🤐 Unzip artifact | |
run: unzip -O UTF-8 -qq ${{ env.DOC_ARTIFACT }} -d dir | |
- name: Setup Pages | |
uses: actions/configure-pages@v2 | |
- name: Upload artifact to GH Pages | |
uses: actions/upload-pages-artifact@v1 | |
with: | |
path: dir | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v1 | |