Skip to content

MultiOS-USB.version: 0.9.2 -> 0.9.3 #9

MultiOS-USB.version: 0.9.2 -> 0.9.3

MultiOS-USB.version: 0.9.2 -> 0.9.3 #9

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
jobs:
build_image:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Set version
run: echo "ver=$(git describe --tags --exact-match)" >> "$GITHUB_ENV"
- name: Linux Release
run: git archive --prefix=MultiOS-USB_$ver/ -o MultiOS-USB_linux_$ver.tar.gz $ver
- name: Windows Release
run: |
efiPartSize="$(grep ^efi_size= multios-usb.sh | cut -f2- -d'=' | xargs)"
imageName="image.img"
imageSize=$(($(echo $efiPartSize | sed 's/\([0-9]\+\)\([A-Za-z]\)/\1/') + 2))
tmp_imageName="tmp.img"
tmp_imageSize="$(($imageSize + 50))$(echo $efiPartSize | sed 's/\([0-9]\+\)\([A-Za-z]\)/\2/')"
fallocate $tmp_imageName -l $tmp_imageSize
dev=$(sudo losetup -f -P --show $tmp_imageName)
echo "YeS" | sudo ./multios-usb.sh $dev
mkdir part_data && sudo mount ${dev}p2 part_data
(cd part_data && sudo zip -r ../files.zip *)
sudo umount ${dev}p2
sudo dd if=$dev of=$imageName bs=1M count=$imageSize
sudo sgdisk -d 2 $imageName
mv docs/README_image README.txt
sudo zip MultiOS-USB_windows_image_$ver.zip $imageName files.zip README.txt
- name: Generate SHA256SUM
run: sha256sum MultiOS-USB_windows_image_*.zip MultiOS-USB_linux_*.tar.gz > sha256sums.txt
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: false
files: |
MultiOS-USB_windows_image_*.zip
MultiOS-USB_linux_*.tar.gz
sha256sums.txt