feat: windows portable version do not check update
This commit is contained in:
parent
7eb595170f
commit
d5192e2244
5
.github/workflows/ci.yml
vendored
5
.github/workflows/ci.yml
vendored
@ -77,10 +77,15 @@ jobs:
|
||||
|
||||
- name: Portable Bundle
|
||||
if: matrix.os == 'windows-latest'
|
||||
# rebuild with env settings
|
||||
run: |
|
||||
yarn build
|
||||
yarn run portable
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
TAURI_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
|
||||
TAURI_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
|
||||
VITE_WIN_PORTABLE: 1
|
||||
|
||||
release-update:
|
||||
needs: release
|
||||
|
@ -22,6 +22,10 @@ import useCustomTheme from "@/components/layout/use-custom-theme";
|
||||
import getSystem from "@/utils/get-system";
|
||||
import "dayjs/locale/zh-cn";
|
||||
|
||||
declare global {
|
||||
const WIN_PORTABLE: boolean;
|
||||
}
|
||||
|
||||
dayjs.extend(relativeTime);
|
||||
|
||||
const OS = getSystem();
|
||||
@ -87,7 +91,9 @@ const Layout = () => {
|
||||
<div className="the-logo" data-windrag>
|
||||
<LogoSvg />
|
||||
|
||||
{!(OS === "windows" && WIN_PORTABLE) && (
|
||||
<UpdateButton className="the-newbtn" />
|
||||
)}
|
||||
</div>
|
||||
|
||||
<List className="the-menu">
|
||||
|
@ -22,4 +22,7 @@ export default defineConfig({
|
||||
"@root": path.resolve("."),
|
||||
},
|
||||
},
|
||||
define: {
|
||||
WIN_PORTABLE: !!process.env.VITE_WIN_PORTABLE,
|
||||
},
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user