Skip to content

Commit

Permalink
Merge pull request #345 from cole-miller/v2-packages
Browse files Browse the repository at this point in the history
v2 packages
  • Loading branch information
cole-miller authored Oct 23, 2024
2 parents ac71710 + 557b450 commit 3bd68f5
Showing 1 changed file with 16 additions and 9 deletions.
25 changes: 16 additions & 9 deletions .github/workflows/packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Build PPA source packages
on:
push:
branches:
- master
- v2
jobs:
build:
if: github.repository == 'canonical/go-dqlite'
Expand All @@ -18,10 +18,16 @@ jobs:
environment:
name: ppa
steps:
- name: Clone the repositories
run: |
git clone https://github.com/canonical/go-dqlite
git clone https://github.com/canonical/dqlite-ppa -b go-dqlite --depth 1
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true

- uses: actions/checkout@v4
with:
repository: canonical/dqlite-ppa
ref: go-dqlite-v2
path: dqlite-ppa

- name: Setup dependencies
run: |
Expand All @@ -46,17 +52,18 @@ jobs:
DEBEMAIL: "[email protected]"
TARGET: ${{ matrix.target }}
run: |
cp -R dqlite-ppa/debian go-dqlite/
cd go-dqlite/
cp -R dqlite-ppa/debian .
go mod vendor
VERSION="$(git describe --tags | sed -e "s/^v//" -e "s/-/+git/")"
dch --create \
--distribution ${TARGET} \
--package go-dqlite \
--package go-dqlite-v2 \
--newversion ${VERSION}~${TARGET}1 \
"Automatic build from Github"
debuild -S -sa -d -k${{ vars.PPA_PUBLIC_KEY }}
- name: Upload to Launchpad
run: |
dput -U -u ppa:dqlite/dev *.changes
cd ..
shopt -s globstar
dput -U -u ppa:dqlite/dev **/*.changes

0 comments on commit 3bd68f5

Please sign in to comment.