RandomHQRandomHQ

代码和运行

Git 仓库和项目运行

代码操作

git clone git@gitlab.com:[user-name]/[repo-name].git

建议是从 gitlab fork 到新项目仓库,然后克隆新的仓库代码。

新克隆的代码仓库,建议 3 个远程仓库:

  • lab 是 gitlab 远程仓库,从 gitlab 克隆的仓库
  • hub 是 github 远程仓库,方便 vercel 部署
  • ups 是 gitlab 的上游仓库,方便同步上游模板仓库的基础功能
git remote add lab https://gitlab.com/[user-name]/[repo-name].git
git remote add hub https://github.com/[user-name]/[repo-name].git
git remote add ups git@gitlab.com:[user-name]/[repo-name].git

同步上游仓库

git fetch ups
git merge ups/main
git push hub

环境配置

  • 环境变量 (env)

项目运行

安装依赖

pnpm install

运行项目

pnpm dev

部署项目

pnpm build