feat: add version info
All checks were successful
/ deploy_site (push) Successful in 24s

This commit is contained in:
Minhyeok Park 2024-11-13 15:29:35 +09:00
parent 2f400f5e48
commit 8214b7807c
Signed by: pmh_only
SSH Key Fingerprint: SHA256:g/OyGvi2pcd8ub9mqge/ohmDP0fZX/xOPWPIcM+9XpI
4 changed files with 10 additions and 2 deletions

View File

@ -10,6 +10,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- run: mc alias set minio http://minio-service.minio.svc.cluster.local:9000 ${{ secrets.MINIO_ACCESS_KEY }} ${{ secrets.MINIO_SECRET_KEY }}
- run: echo "export const VERSION = '$(git rev-parse --short HEAD)'" > src/version.ts
- run: pnpm i
- run: pnpm build
- run: mc mirror $PWD/dist/ minio/ptools --overwrite

View File

@ -3,6 +3,7 @@ import { Editor as MonacoEditor } from "@monaco-editor/react";
import { useRecoilState } from "recoil";
import { EditorValueState } from "../GlobalStates/EditorValueState";
import { motion } from "framer-motion";
import { VERSION } from "../version";
import style from "./style.module.scss";
@ -57,8 +58,9 @@ export const Editor: FC = () => {
<div className={style.credit}>
<div className={style.creditstr}>
<p>The PTOOLS v2</p>
<p>Made by Minhyeok Park</p>
<p><b>The PTOOLS</b></p>
<p>v2-{VERSION}</p>
<p>&copy; Minhyeok Park</p>
</div>
<img className={style.suika} src="/suika.webp" />
</div>

View File

@ -14,6 +14,10 @@
opacity: 0.25;
pointer-events: none;
b {
font-weight: 900;
}
.suika {
width: 140px;
}

1
src/version.ts Normal file
View File

@ -0,0 +1 @@
export const VERSION = 'deadbeef'