22 push :
33 paths :
44 - ' src/**'
5- - ' !src/debian/changelog'
65# branches: master
76
87jobs :
@@ -60,24 +59,13 @@ jobs:
6059 run : |
6160 DESTDIR=${ROOT_FS} make install
6261
63- # TODO: move the devscripts installation into docker container image build
64- - name : Bump the package version
62+ - name : Read the package version
6563 working-directory : usbproxy
66- id : bump- version
64+ id : version
6765 run : |
68- VERSION=$(cat ./VERSION)
69- NEW_VERSION=$(semver bump patch $VERSION)
70- apt-get install -y devscripts
71- cd ./src && dch -v ${NEW_VERSION} --distribution main "$(git log -1 --pretty=%B)" --force-distribution
66+ NEW_VERSION=$(cat ./VERSION)
7267 echo '::set-output name=NEW_VERSION::$NEW_VERSION'
7368
74- # commit the changelog modification
75- - uses : EndBug/add-and-commit@v7
76- with :
77- add : src/debian/changelog
78- cwd : usbproxy
79- message : " chore: modify changelog"
80-
8169 - name : Build the debian package
8270 working-directory : usbproxy/src
8371 run : |
9583 uses : mathieudutour/github-tag-action@v5.1
9684 with :
9785 github_token : ${{ secrets.GITHUB_TOKEN }}
98- custom_tag : " ${{ steps.bump- version.outputs.NEW_VERSION }}"
86+ custom_tag : " ${{ steps.version.outputs.NEW_VERSION }}"
9987
10088 - name : Create a GitHub release
10189 uses : actions/create-release@v1
@@ -114,8 +102,8 @@ jobs:
114102 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
115103 with :
116104 upload_url : ${{ steps.create_release.outputs.upload_url }}
117- asset_path : usbproxy/nesto-usbproxy_${{ steps.bump- version.outputs.NEW_VERSION }}_armhf.deb
118- asset_name : nesto-usbproxy_${{ steps.bump- version.outputs.NEW_VERSION }}_armhf.deb
105+ asset_path : usbproxy/nesto-usbproxy_${{ steps.version.outputs.NEW_VERSION }}_armhf.deb
106+ asset_name : nesto-usbproxy_${{ steps.version.outputs.NEW_VERSION }}_armhf.deb
119107 asset_content_type : application/vnd.debian.binary-package
120108
121109 upload-package :
0 commit comments