From 6d775107ad4f147d976158ebd0f7583f56c30959 Mon Sep 17 00:00:00 2001 From: Chris Titus Date: Thu, 18 Jul 2024 16:29:02 -0500 Subject: [PATCH] prerelease fix --- .github/workflows/pre-release.yaml | 6 +++--- .github/workflows/rust.yml | 4 +++- src/theme.rs | 4 ++-- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/pre-release.yaml b/.github/workflows/pre-release.yaml index 9f36e8e4..c08f1533 100644 --- a/.github/workflows/pre-release.yaml +++ b/.github/workflows/pre-release.yaml @@ -18,15 +18,15 @@ jobs: id: extract_version run: | version=$(date +"%Y.%m.%d") - echo "version=$version" >> $env:GITHUB_ENV + echo "version=$version" >> GITHUB_ENV shell: bash - name: Create and Upload Release id: create_release uses: softprops/action-gh-release@v2 with: - tag_name: ${{ env.VERSION }} - name: Pre-Release ${{ env.VERSION }} + tag_name: ${{ env.version }} + name: Pre-Release ${{ env.version }} body: "![GitHub Downloads (specific asset, specific tag)](https://img.shields.io/github/downloads/ChrisTitusTech/linutil/${{ env.VERSION }}/linutil)" append_body: false files: | diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 884f8426..b5a05d35 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -35,4 +35,6 @@ jobs: with: toolchain: stable - name: Build - run: cargo build --release --verbose \ No newline at end of file + run: cargo build --release --verbose + + \ No newline at end of file diff --git a/src/theme.rs b/src/theme.rs index 2c3f2d29..c741e75b 100644 --- a/src/theme.rs +++ b/src/theme.rs @@ -31,9 +31,9 @@ pub const THEMES: [Theme; 2] = [ ]; pub fn get_theme() -> &'static Theme { - return &THEMES[unsafe {THEME_IDX} ]; + &THEMES[unsafe { THEME_IDX } ] } pub fn set_theme(idx: usize){ - unsafe {THEME_IDX = idx}; + unsafe { THEME_IDX = idx }; }