Skip to content

Commit

Permalink
revert old changes
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkNerdi committed Jul 3, 2024
1 parent 24cca6e commit 69fd47a
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 60 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-and-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ jobs:
needs: [setup]
strategy:
matrix:
os: [ubuntu-20.04]
os: [ubuntu-20.04, windows-2022, macos-12]
fail-fast: true
with:
os: ${{ matrix.os }}
Expand Down
125 changes: 67 additions & 58 deletions .github/workflows/reusable_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,17 +28,17 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

# - name: Downloading artifacts (Windows)
# uses: actions/download-artifact@v4
# with:
# name: bloom-desktop-windows-2022
# path: assets
- name: Downloading artifacts (Windows)
uses: actions/download-artifact@v4
with:
name: bloom-desktop-windows-2022
path: assets

# - name: Downloading artifacts (macOS)
# uses: actions/download-artifact@v4
# with:
# name: bloom-desktop-macos-12
# path: assets
- name: Downloading artifacts (macOS)
uses: actions/download-artifact@v4
with:
name: bloom-desktop-macos-12
path: assets

- name: Downloading artifacts (Linux)
uses: actions/download-artifact@v4
Expand All @@ -49,7 +49,11 @@ jobs:
- name: Preparing release body
run: |
sed -i 's/\r$//' ../../assets/*.sha256 && sed -i '/^$/d' ../../assets/*.sha256 && sed -i -e 's/\(.*\)/\L\1/' ../../assets/*.sha256
WIN_SHA256=$(cat ../../assets/bloom-desktop-${{ env.VERSION }}.exe.sha256)
WIN_BLOCKMAP_SHA256=$(cat ../../assets/bloom-desktop-${{ env.VERSION }}.exe.blockmap.sha256)
LIN_SHA256=$(cat ../../assets/bloom-desktop-${{ env.VERSION }}.AppImage.sha256)
MAC_SHA256=$(cat ../../assets/bloom-desktop-${{ env.VERSION }}.dmg.sha256)
MAC_BLOCKMAP_SHA256=$(cat ../../assets/bloom-desktop-${{ env.VERSION }}.dmg.blockmap.sha256)
echo $WIN_SHA256 $LIN_SHA256 $MAC_SHA256
touch CHANGELOG.md
echo '### Changelog' >> CHANGELOG.md
Expand All @@ -58,56 +62,14 @@ jobs:
echo '[How to verify the authenticity of your Bloom Desktop download](https://wiki.iota.org/shimmer/introduction/how_tos/verify_download/#verify-your-firefly-desktop-download)' >> CHANGELOG.md
echo '| File | Platform | SHA256 Hash |' >> CHANGELOG.md
echo '| --- | --- | --- |' >> CHANGELOG.md
echo '| bloom-desktop-${{ env.VERSION }}.exe | Windows |' $WIN_SHA256 '|' >> CHANGELOG.md
echo '| bloom-desktop-${{ env.VERSION }}.exe.blockmap | Windows |' $WIN_BLOCKMAP_SHA256 '|' >> CHANGELOG.md
echo '| bloom-desktop-${{ env.VERSION }}.AppImage | Linux |' $LIN_SHA256 '|' >> CHANGELOG.md
echo '| bloom-desktop-${{ env.VERSION }}.dmg | MacOS |' $MAC_SHA256 '|' >> CHANGELOG.md
echo '| bloom-desktop-${{ env.VERSION }}.dmg.blockmap | MacOS |' $MAC_BLOCKMAP_SHA256 '|' >> CHANGELOG.md
cat CHANGELOG.md
working-directory: packages/desktop

# - name: Create Release
# id: create_release
# uses: actions/[email protected]
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# with:
# tag_name: ${{ github.ref }}
# release_name: Bloom Desktop ${{ env.RELEASE_NAME }}
# body_path: packages/desktop/CHANGELOG.md
# draft: true
# prerelease: true

# - name: Upload Linux assets
# run: |
# gh release upload $RELEASE_NAME $BINARY $UPDATER $SIGNATURE --clobber
# env:
# RELEASE_NAME: Bloom Desktop ${{ env.RELEASE_NAME }}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# BINARY: assets/bloom-desktop-${{ env.VERSION }}.AppImage
# SIGNATURE: assets/bloom-desktop-${{ env.VERSION }}.AppImage.asc
# UPDATER: assets/latest-linux.yml
# shell: bash

# - name: Upload Mac assets
# run: |
# gh release upload $RELEASE_NAME $BLOCKMAP $BINARY $ZIP $UPDATER --clobber
# env:
# RELEASE_NAME: Bloom Desktop ${{ env.RELEASE_NAME }}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# BLOCKMAP: assets/bloom-desktop-${{ env.VERSION }}.dmg.blockmap
# BINARY: assets/bloom-desktop-${{ env.VERSION }}.dmg
# ZIP: assets/bloom-desktop-${{ env.VERSION }}.zip
# UPDATER: assets/latest-mac.yml
# shell: bash

# - name: Upload Windows assets
# run: |
# gh release upload $RELEASE_NAME $BINARY $BLOCKMAP $UPDATER --clobber
# env:
# RELEASE_NAME: Bloom Desktop ${{ env.RELEASE_NAME }}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# BINARY: assets/bloom-desktop-${{ env.VERSION }}.exe
# BLOCKMAP: assets/bloom-desktop-${{ env.VERSION }}.exe.blockmap
# UPDATER: assets/latest.yml
# shell: bash

- name: Create Release
uses: "actions/github-script@v7"
id: create_release
Expand Down Expand Up @@ -148,9 +110,56 @@ jobs:

return createReleaseResponse.data.upload_url;

- name: Upload Windows assets
uses: "actions/github-script@v7"
env:
VERSION: ${{ env.VERSION }}
UPLOAD_URL: ${{ steps.create_release.outputs.result }}
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
script: |
const fs = require('fs').promises;
const { VERSION, UPLOAD_URL } = process.env;
const files = [
`bloom-desktop-${VERSION}.exe`,
`bloom-desktop-${VERSION}.exe.blockmap`,
'latest.yml'
]
for (const file of files) {
await github.rest.repos.uploadReleaseAsset({
url: UPLOAD_URL,
name: file,
data: await fs.readFile('assets/' + file)
});
}

- name: Upload Mac assets
uses: "actions/github-script@v7"
env:
VERSION: ${{ env.VERSION }}
UPLOAD_URL: ${{ steps.create_release.outputs.result }}
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
script: |
const fs = require('fs').promises;
const { VERSION, UPLOAD_URL } = process.env;
const files = [
`bloom-desktop-${VERSION}.dmg`,
`bloom-desktop-${VERSION}.dmg.blockmap`,
`bloom-desktop-${VERSION}.zip`,
'latest-mac.yml'
]
for (const file of files) {
await github.rest.repos.uploadReleaseAsset({
url: UPLOAD_URL,
name: file,
data: await fs.readFile('assets/' + file)
});
}
- name: OUTPUT
run: echo "${{ steps.create_release.outputs.result }}"

- name: Upload Linux assets
uses: "actions/github-script@v7"
Expand Down
2 changes: 1 addition & 1 deletion packages/desktop/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "desktop",
"productName": "Bloom",
"version": "0.0.16-alpha-20",
"version": "0.0.16-alpha-21",
"description": "Simple and secure web3 wallet for the IOTA and Shimmer ecosystem",
"main": "public/build/main.process.js",
"repository": "[email protected]:bloomwalletio/bloom.git",
Expand Down

0 comments on commit 69fd47a

Please sign in to comment.