Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update version in repo after a release #201

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
82fdb9c
Updated release action to make it commit the latest changes to repo a…
walkero-gr Aug 16, 2024
0de506f
Merge pull request #6 from walkero-gr/update-version-in-repo-after-a-…
walkero-gr Aug 16, 2024
cbb8a36
Disabled temporarily the release to the ubuntu server
walkero-gr Aug 16, 2024
1596776
Merge pull request #7 from walkero-gr/update-version-in-repo-after-a-…
walkero-gr Aug 16, 2024
c451030
Fixing the "fatal: detected dubious ownership in repository"
walkero-gr Aug 16, 2024
3903bbc
Merge pull request #8 from walkero-gr/update-version-in-repo-after-a-…
walkero-gr Aug 16, 2024
dcf90a9
Fixing issues with commit
walkero-gr Aug 16, 2024
9cefcab
Changed the safe.directory config
walkero-gr Aug 16, 2024
e8f04ee
Changed the push command
walkero-gr Aug 16, 2024
3bbbfc6
git force push
walkero-gr Aug 16, 2024
6b0a035
Added creation of a PR
walkero-gr Aug 16, 2024
fb4c61a
Changed the PR
walkero-gr Aug 16, 2024
43e1dba
updated the PR again
walkero-gr Aug 17, 2024
963ce8a
Added short sommit hash in the VERSTAG
walkero-gr Aug 17, 2024
28a68da
Trying Pull Request Automerge
walkero-gr Aug 17, 2024
6fd6037
Added a step to install gh binary
walkero-gr Aug 17, 2024
aa70d05
Updated the code to install gh binary
walkero-gr Aug 17, 2024
6217c38
Release v2.1.12 changes (#11)
github-actions[bot] Aug 17, 2024
683a443
A small fix in Makefile
walkero-gr Aug 17, 2024
8796e09
Release v2.1.13 changes (#12)
github-actions[bot] Aug 17, 2024
5b0091e
Added /opt/code to safe directories
walkero-gr Aug 17, 2024
070822d
Release v2.1.14 changes (#13)
github-actions[bot] Aug 17, 2024
d73715d
Enabled compilation again
walkero-gr Aug 17, 2024
6c68a9f
Release v2.1.17 changes (#14)
github-actions[bot] Aug 17, 2024
acbb46c
Changed the digita to multinumbers
walkero-gr Aug 17, 2024
a485fda
Release v2.1.18 changes (#15)
github-actions[bot] Aug 17, 2024
9585262
Fixed the versions
walkero-gr Aug 17, 2024
bad9c94
Enabled again the upload of the DEB file to the ubuntu repo
walkero-gr Aug 17, 2024
f1fa673
A few changes in gitignore
walkero-gr Aug 17, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .github/workflows/makeRelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ jobs:
steps:
- name: Pull code
uses: actions/checkout@v4
- name: Add repository to git safe directories
run: |
git config --global --add safe.directory $GITHUB_WORKSPACE
git config --global --add safe.directory /opt/code
- name: Compile clib4
run: |
cd /opt/code && \
Expand All @@ -37,6 +41,14 @@ jobs:
asset_path: /opt/code/clib4-${{ github.event.release.tag_name }}.lha
asset_name: clib4-${{ github.event.release.tag_name }}.lha
asset_content_type: application/x-lzh-compressed
- name: Install gh binary
run: |
mkdir -p -m 755 /etc/apt/keyrings \
&& wget -qO- https://cli.github.com/packages/githubcli-archive-keyring.gpg | tee /etc/apt/keyrings/githubcli-archive-keyring.gpg > /dev/null \
&& chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg \
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | tee /etc/apt/sources.list.d/github-cli.list > /dev/null \
&& apt update \
&& apt install gh -y
- name: Upload DEB release file in GitHub
uses: actions/upload-release-asset@v1
env:
Expand All @@ -59,6 +71,21 @@ jobs:
rm /opt/amigarepo/ubuntu/pool/main/clib4*.deb
after_script: |
/root/regenerate-packages.sh
- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v6
with:
commit-message: Release ${{ github.event.release.tag_name }} changes
branch: release/${{ github.event.release.tag_name }}
base: master
body: Automated changes as part of the release
title: Version files changes by the github bot
- name: Enable Pull Request Automerge
if: steps.cpr.outputs.pull-request-operation == 'created'
uses: peter-evans/enable-pull-request-automerge@v3
with:
pull-request-number: ${{ steps.cpr.outputs.pull-request-number }}
merge-method: squash
# - name: Prepare OS4Depot release
# run: |
# mkdir os4depot-release
Expand Down
19 changes: 11 additions & 8 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,17 @@
!libs/libauto.a
*.lha
*.bak
*.deb
*.map

/library/compiler.log
clib4.info
compiler.log
*.map
.vscode
build/
clib4.info
clib4.lha
.idea/
clib4_1.0_amd64
*.deb
clib4/
clib4-*_amd64

build/
clib4/

.idea
.vscode
8 changes: 5 additions & 3 deletions GNUmakefile.os4
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ ifneq ($(origin GITTAG),undefined)
MAJOR = $(patsubst v%,%,$(firstword $(subst ., ,$(GITTAG))))
MINOR = $(word 2, $(subst ., ,$(GITTAG)))
PATCH = $(word 3, $(subst ., ,$(GITTAG)))
GIT_HASH = $(shell git rev-parse --short HEAD)
endif

##############################################################################
Expand Down Expand Up @@ -253,10 +254,11 @@ gitver:
$(VERBOSE)sed -i 's/[(]\([0-9]*\.[0-9]*\.[0-9]*\)[)]/($(DATESTR))/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/"\([0-9]*\.[0-9]*\.[0-9]*\)"/"$(DATESTR)"/g' library/c.lib_rev.h
ifdef GITTAG
$(VERBOSE)sed -i 's/VERSION\t*[[:digit:]]/VERSION\t\t\t$(MAJOR)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/REVISION\t*[[:digit:]]/REVISION\t\t$(MINOR)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/SUBREVISION\t*[[:digit:]]/SUBREVISION\t\t$(PATCH)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/VERSION\t*[0-9]*/VERSION\t\t\t$(MAJOR)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/REVISION\t*[0-9]*/REVISION\t\t$(MINOR)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/SUBREVISION\t*[0-9]*/SUBREVISION\t\t$(PATCH)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/clib4.library [0-9]*\.[0-9]*\.[0-9]*/clib4.library $(MAJOR).$(MINOR).$(PATCH)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/clib4.library [0-9]*\.[0-9]*\.[0-9]*-[a-z0-9]*/clib4.library $(MAJOR).$(MINOR).$(PATCH)-$(GIT_HASH)/g' library/c.lib_rev.h
$(VERBOSE)sed -i 's/Version: [0-9]*\.[0-9]*\.[0-9]*/Version: $(MAJOR).$(MINOR).$(PATCH)/g' misc/control
endif

Expand Down
10 changes: 5 additions & 5 deletions library/c.lib_rev.h
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#define VERSION 1
#define REVISION 0
#define REVISION 3
#define SUBREVISION 0

#define DATE "28.05.2024"
#define VERS "clib4.library 1.0.0"
#define VSTRING "clib4.library 1.0.0 (28.05.2024)\r\n"
#define VERSTAG "\0$VER: clib4.library 1.0.0 (28.05.2024)"
#define DATE "04.06.2024"
#define VERS "clib4.library 1.3.0"
#define VSTRING "clib4.library 1.3.0 (04.06.2024)\r\n"
#define VERSTAG "\0$VER: clib4.library 1.3.0-dummy (04.06.2024)"
2 changes: 1 addition & 1 deletion misc/control
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Package: amigaos4-clib4
Version: 1.0.2
Version: 1.3.0
Maintainer: Andrea Palmatè <os4test@amigasoft.net>
Architecture: amd64
Section: libdevel
Expand Down