Update README.md #120
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest] | |
steps: | |
- name: Setup cmake | |
uses: jwlawson/[email protected] | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Setup Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- name: Hakoniwa-core | |
run: | | |
bash build.bash | |
- name: Artifact Name for ubuntu | |
if: matrix.os == 'ubuntu-latest' | |
run: | | |
echo "ARTIFACT_NAME=libshakoc.so" >> $GITHUB_ENV | |
echo "ARTIFACT_PATH=cmake-build/src/hakoc/libshakoc.so" >> $GITHUB_ENV | |
- name: Artifact Name for mac | |
if: matrix.os == 'macos-latest' | |
run: | | |
echo "ARTIFACT_NAME=libshakoc.dylib" >> $GITHUB_ENV | |
echo "ARTIFACT_PATH=cmake-build/src/hakoc/libshakoc.dylib" >> $GITHUB_ENV | |
- name: upload Artifact | |
if: startsWith(github.ref, 'refs/tags/v') | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{env.ARTIFACT_NAME}} | |
path: ${{env.ARTIFACT_PATH}} | |
- name: Publish archives and packages | |
if: startsWith(github.ref, 'refs/tags/v') | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
${{ env.ARTIFACT_PATH }} |