Refactor spawn_process fn to handle spawn error

This commit modifies the spawn_process function to explicitly return a Result type, handling the error of the spawn() method. This change improves the readability of the error handling and makes it more idiomatic in Rust. As a secondary correction, it fixes a typo in a print statement.
This commit is contained in:
Ian Wijma 2023-11-21 00:31:40 +11:00
parent 563938e51a
commit df5776e76d
2 changed files with 11 additions and 1 deletions

View File

@ -18,9 +18,19 @@ jobs:
steps:
- uses: actions/checkout@master
- name: Compile and release
id: compile
uses: rust-build/rust-build.action@v1.4.4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
RUSTTARGET: ${{ matrix.target }}
ARCHIVE_TYPES: ${{ matrix.archive }}
UPLOAD_MODE: 'none'
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Binary
path: |
${{ steps.compile.outputs.BUILT_ARCHIVE }}
${{ steps.compile.outputs.BUILT_CHECKSUM }}

View File

@ -1,6 +1,6 @@
[package]
name = "kr"
version = "1.0.0"
version = "1.0.1"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html