Skip to content

Commit

Permalink
More work for getting our CI system going. (#383)
Browse files Browse the repository at this point in the history
* More work.

* Adding releases as additional step.

* Redoing things as two steps

* Doing this again.

* Updating the latest flows.

* Fixing up yml

* Finishing up the release instructions.
  • Loading branch information
rmpowell77 committed Aug 2, 2021
1 parent 41d10a5 commit 3ce32cf
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 42 deletions.
38 changes: 22 additions & 16 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@ on:
push:
branches:
- main
tags:
- '*'
pull_request:
branches:
- main
create:

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
Expand All @@ -27,19 +28,19 @@ jobs:
- {
name: "Ubuntu Latest GCC",
artifact: "CalChart.tar.xz",
artifact_name: "CalChart-Linux.tar.xz",
artifact_name: "CalChart-Linux",
os: ubuntu-latest,
}
- {
name: "macOS Latest Clang",
artifact: "CalChart-*.dmg",
artifact_name: "CalChart-macOS.dmg",
artifact_name: "CalChart-macOS",
os: macos-latest,
}
- {
name: "Windows Latest MSVC",
artifact: "CalChart-*.exe",
artifact_name: "CalChart-Windows.exe",
artifact_name: "CalChart-Windows",
os: windows-latest,
}

Expand Down Expand Up @@ -96,25 +97,30 @@ jobs:
path: ${{github.workspace}}/build/${{ matrix.config.artifact }}
name: ${{ matrix.config.artifact_name }}


release:
if: contains(github.ref, 'tags/v')
name: ${{ matrix.config.name }}
name: Release
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config:
- artifact: "CalChart.tar.xz"
- artifact: "CalChart-*.dmg"
- artifact: "CalChart-*.exe"
needs: build
steps:
- name: checkout
uses: actions/checkout@v2

- name: Download artifact
uses: actions/download-artifact@v2
with:
path: ./

- name: Display structure of downloaded files
run: ls -R

# using https://github.com/ncipollo/release-action
- name: release
- name: Release
uses: ncipollo/release-action@v1
with:
artifacts: ${{github.workspace}}/build/${{ matrix.config.artifact }}
bodyFile: "LATEST_RELEASE_NOTES.md"
artifacts: CalChart-*/*
bodyFile: ./LATEST_RELEASE_NOTES.md
draft: true
token: ${{ secrets.GITHUB_TOKEN }}

54 changes: 28 additions & 26 deletions RELEASE_INSTRUCTIONS.md
Original file line number Diff line number Diff line change
@@ -1,55 +1,57 @@
~=~=~=~=~=~=~=~=~=~=~
---

Checklist

[] Did you run clang format on all the files? (clang-format -style="{BasedOnStyle: webkit}" -i src/*)
[] Did it build on both windows and mac?
[] Did you open and close some files?
* Did you run clang format on all the files? (`clang-format -style="{BasedOnStyle: webkit}" -i src/*`)
* Did it build on both windows and mac?
* Did you open and close some files?

---

# How to release calchart:

~=~=~=~=~=~=~=~=~=~=~
CalChart uses CMake and Github actions to automate the release process. When you push a tag for the repository, github will build and package the release.

How to release calchart:
The current calchart version is 3.6.3. In all commands below, substitute that number for `$CCVER` (meaning when you read `$CCVER`, type 3.6.3)

The current calchart version is 3.6.3. In all commands below, substitute that number for $CCVER (meaning when you read $CCVER, type 3.6.3)
1. Prebuild the project to make sure its working

0.1 LATEST_RELEASE_NOTES.md will get posted to the release by our CI bot, so update what bugs have been fixed.
2. Update LATEST_RELEASE_NOTES.md with all the changes (it will get posted to the release by our CI bot)

0.2 copy LATEST_RELEASE_NOTES.md into master README.md for the master record via this command:
3. copy LATEST_RELEASE_NOTES.md into master README.md for the master record via this command:

```
awk '//; /^# Release notes/{while(getline<"LATEST_RELEASE_NOTES.md"){print}}' README.md > tmp && mv tmp README.md
```

Because you sometimes run into build issues on one platform instead of another, do a build before you do a tag:
1. Prebuild the project to make sure its working

2. Tag the depot
4. Tag the depot

```
$ git tag -a v3.6.3 -m "calchart-3.6.3"
$ git push origin v3.6.3
```

This should trigger the github actions
This should trigger the github action, which should publish release notes in Draft form.

5. Once the Release information looks good, Press the Publish Release button.

4. Go to the git Go to the sourceforge page at http://sourceforge.net/projects/calchart
You'll need to be logged in as Administrator to modify the files.
6. Download the Release artifacts to your machine.

5. Go to the sourceforge page at http://sourceforge.net/projects/calchart
You'll need to be logged in as Administrator to modify the files.
7. Go to the sourceforge page at http://sourceforge.net/projects/calchart. You'll need to be logged in as Administrator to modify the files.

6. Go to Project Admin -> File Manager
8. Go to Project Admin -> File Manager

7. Make a new directory for this version (click on the * next to root)
9. Make a new directory for this version (click on the * next to root)

8. Upload the README.txt to the new folder. Click on README.txt and edit the file details to signify it's a release notes.
10. Upload the `README.md` to the new folder. Click on `README.md` and edit the file details to signify it's a release notes.

9. Upload the CalChart-$CCVER.dmg to the folder. Click on dmg and edit the file details to signify its platform is Mac (OS X) and set the release_notes for the file.
11. Upload the `CalChart-$CCVER.dmg` to the folder. Click on dmg and edit the file details to signify its platform is Mac (OS X) and set the release_notes for the file.

10. Repeat for Install-CalChart-$CCVER.exe. Click on zip and edit the file details to signify its platform is Windows and set the release_notes for the file.
12. Repeat for `Install-CalChart-$CCVER.exe`. Click on zip and edit the file details to signify its platform is Windows and set the release_notes for the file.

11. Update https://github.com/calband/calchart/releases with Readme version updates.
13. Update https://github.com/calband/calchart/milestone by closing the shipped milestone and starting the next one.

12. Update https://github.com/calband/calchart/milestone by closing the shipped milestone and starting the next one.
14. Notify the world about the new version of CalChart.

13. Have a cookie.
15. Have a cookie.

0 comments on commit 3ce32cf

Please sign in to comment.