Skip to content

Commit

Permalink
Build gopy package on the fly
Browse files Browse the repository at this point in the history
  • Loading branch information
blefaudeux committed Sep 30, 2024
1 parent e127b08 commit 3526791
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 21 deletions.
41 changes: 20 additions & 21 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,33 @@ name: Go

on:
push:
branches: [ "main" ]
branches: ["main"]
pull_request:
branches: [ "main" ]
branches: ["main"]

jobs:

build:
build_and_test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.20'
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: "1.20"

- name: Install linux deps
run: |
sudo apt-get update
sudo apt-get -y install libvips-dev
- name: Install linux deps
run: |
sudo apt-get update
sudo apt-get -y install libvips-dev
- name: Build
run: cd src/cmd/main && go build -v main.go
- name: Build
run: cd src/cmd/main && go build -v main.go

- name: Test
env:
DATAROOM_API_KEY: ${{ secrets.DATAROOM_API_KEY }}
DATAROOM_TEST_SOURCE: ${{ secrets.DATAROOM_TEST_SOURCE }}
DATAROOM_API_URL: ${{ secrets.DATAROOM_API_URL }}
- name: Test
env:
DATAROOM_API_KEY: ${{ secrets.DATAROOM_API_KEY }}
DATAROOM_TEST_SOURCE: ${{ secrets.DATAROOM_TEST_SOURCE }}
DATAROOM_API_URL: ${{ secrets.DATAROOM_API_URL }}

run: cd src/tests && go test -v .
run: cd src/tests && go test -v .
41 changes: 41 additions & 0 deletions .github/workflows/gopy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# This workflow will build a gopy project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go

name: Gopy

on:
push:
branches: ["main"]
pull_request:
branches: ["main"]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install linux deps
run: |
sudo apt-get update
sudo apt-get -y install libvips-dev libjpeg-turbo8-dev
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: "1.23"

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.11"

- name: Install pybindgen
run: |
python3 -m pip install pybindgen
go install golang.org/x/tools/cmd/goimports@latest
go install github.com/go-python/gopy@latest
- name: Build
run: |
cd src/pkg/client && gopy pkg -author="Photoroom" -email="[email protected]" -url="" -name="datago" -version="0.99" .

0 comments on commit 3526791

Please sign in to comment.