Skip to content
This repository has been archived by the owner on Sep 15, 2024. It is now read-only.

Commit

Permalink
Fix CI build problem
Browse files Browse the repository at this point in the history
 * Upgrade to Ubuntu 23.04 before the build starts
 * Update Python version to 3.11
 * Update GH action tools, remove deprecation warnings
  • Loading branch information
mysticfall committed Jul 31, 2023
1 parent d464d3b commit bffaf12
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 14 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/01lunar.list
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
deb http://archive.ubuntu.com/ubuntu/ lunar main restricted
deb http://archive.ubuntu.com/ubuntu/ lunar-updates main restricted

deb http://archive.ubuntu.com/ubuntu/ lunar universe
deb http://archive.ubuntu.com/ubuntu/ lunar-updates universe

2 changes: 2 additions & 0 deletions .github/workflows/01ubuntu
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
APT::Default-Release "lunar";

42 changes: 28 additions & 14 deletions .github/workflows/publish-for-blender-snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,31 @@ on:
workflow_dispatch:

env:
PYTHON_VERSION: "3.10"
PYTHON_VERSION: "3.11"

jobs:
build:
name: Build Blender
runs-on: ubuntu-22.04

steps:
- name: Setup APT
run: |
sudo curl https://raw.githubusercontent.com/mysticfall/bpystubgen/fix-ci/.github/workflows/01lunar.list \
-o /etc/apt/sources.list.d/01lunar.list && \
sudo curl https://raw.githubusercontent.com/mysticfall/bpystubgen/fix-ci/.github/workflows/01ubuntu \
-o /etc/apt/apt.conf.d/01ubuntu
- name: Install Tools
run: |
sudo apt update && \
sudo apt install -t jammy-backports libopenimageio-dev && \
sudo apt dist-upgrade && \
sudo apt install -y build-essential cmake libembree-dev \
libxi-dev libxxf86vm-dev libboost-dev libboost-locale-dev libgl1-mesa-dev \
libavformat-dev libtbb2-dev libswscale-dev libavdevice-dev libblas3 \
libavformat-dev libswscale-dev libavdevice-dev libblas3 libopenimageio-dev \
libzstd-dev libopenimageio-dev libfreetype-dev libepoxy-dev libdecor-0-dev
- name: Install Python
uses: actions/setup-python@v2.3.1
uses: actions/setup-python@v4
with:
python-version: "${{env.PYTHON_VERSION}}"

Expand Down Expand Up @@ -79,7 +85,7 @@ jobs:

- name: Upload Build
if: ${{ !env.ACT }}
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: blender
path: build.tar.gz
Expand All @@ -93,22 +99,30 @@ jobs:
steps:
- name: Download Build
if: ${{ !env.ACT }}
uses: actions/download-artifact@v2
uses: actions/download-artifact@v3
with:
name: blender

- name: Extract Build
if: ${{ !env.ACT }}
run: tar zxvf build.tar.gz

- name: Setup APT
run: |
sudo curl https://raw.githubusercontent.com/mysticfall/bpystubgen/fix-ci/.github/workflows/01lunar.list \
-o /etc/apt/sources.list.d/01lunar.list && \
sudo curl https://raw.githubusercontent.com/mysticfall/bpystubgen/fix-ci/.github/workflows/01ubuntu \
-o /etc/apt/apt.conf.d/01ubuntu
- name: Install Tools
run: |
sudo apt update && \
sudo apt install -y libtbb2 libxi6 libxxf86vm1 libxfixes3 libgl1 \
libavformat58 libavdevice58 libboost-locale1.74.0 libopenimageio-dev
sudo apt dist-upgrade && \
sudo apt install -y libxi6 libxxf86vm1 libxfixes3 libgl1 libtbb12 \
libavformat59 libavdevice59 libboost-locale1.74.0 libopenimageio-dev
- name: Install Python
uses: actions/setup-python@v2.3.1
uses: actions/setup-python@v4
with:
python-version: "${{env.PYTHON_VERSION}}"

Expand All @@ -128,7 +142,7 @@ jobs:
- name: Prepare API Documentation
working-directory: build
run: |
rm -Rf bin/3.2/python && \
rm -Rf bin/4.0/python && \
bin/blender --python-use-system-env --background -noaudio --factory-startup \
--python ../blender/doc/python_api/sphinx_doc_gen.py -- \
--output "${{ github.workspace }}/python_api"
Expand All @@ -139,7 +153,7 @@ jobs:

- name: Upload Documents
if: ${{ !env.ACT }}
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: apidocs
path: apidocs.tar.gz
Expand Down Expand Up @@ -172,7 +186,7 @@ jobs:
run: tar zxvf apidocs.tar.gz

- name: Install Python
uses: actions/setup-python@v2.3.1
uses: actions/setup-python@v4
with:
python-version: "${{env.PYTHON_VERSION}}"

Expand Down Expand Up @@ -200,5 +214,5 @@ jobs:
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_TOKEN }}
packages_dir: python_api/blender-stub/dist
skip_existing: true
packages-dir: python_api/blender-stub/dist
skip-existing: true

0 comments on commit bffaf12

Please sign in to comment.