mirror of
https://github.com/Gar-b-age/CookLikeHOC.git
synced 2026-03-22 04:47:16 +08:00
feat: 更新排除目录列表,添加 docs 目录;新增本地开发文档
This commit is contained in:
@@ -2,7 +2,7 @@ import fs from 'node:fs'
|
|||||||
import path from 'node:path'
|
import path from 'node:path'
|
||||||
|
|
||||||
const DOC_EXT = ['.md']
|
const DOC_EXT = ['.md']
|
||||||
const EXCLUDED_DIRS = new Set(['.git', '.github', '.vitepress', 'node_modules', 'public'])
|
const EXCLUDED_DIRS = new Set(['.git', '.github', '.vitepress', 'node_modules', 'public', 'docs'])
|
||||||
|
|
||||||
function isDirectory(p) {
|
function isDirectory(p) {
|
||||||
return fs.existsSync(p) && fs.statSync(p).isDirectory()
|
return fs.existsSync(p) && fs.statSync(p).isDirectory()
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import fs from 'node:fs'
|
|||||||
import path from 'node:path'
|
import path from 'node:path'
|
||||||
|
|
||||||
const ROOT = process.cwd()
|
const ROOT = process.cwd()
|
||||||
const EXCLUDED_DIRS = new Set(['.git', '.github', '.vitepress', 'node_modules', 'public'])
|
const EXCLUDED_DIRS = new Set(['.git', '.github', '.vitepress', 'node_modules', 'public', 'docs'])
|
||||||
|
|
||||||
function isDirectory(p) {
|
function isDirectory(p) {
|
||||||
return fs.existsSync(p) && fs.statSync(p).isDirectory()
|
return fs.existsSync(p) && fs.statSync(p).isDirectory()
|
||||||
|
|||||||
72
README.md
72
README.md
@@ -1,5 +1,11 @@
|
|||||||

|

|
||||||
|
|
||||||
|
<div align="center">
|
||||||
|
|
||||||
|
[**Docker Support**](./docker_support/README.md) | [**Development**](./docs/development.md)
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
# 像老乡鸡那样做饭
|
# 像老乡鸡那样做饭
|
||||||
|
|
||||||
[**一些说明**](https://github.com/Gar-b-age/CookLikeHOC/issues/26)
|
[**一些说明**](https://github.com/Gar-b-age/CookLikeHOC/issues/26)
|
||||||
@@ -29,70 +35,6 @@
|
|||||||
至于为什么仓库名要叫CookLikeHOC,因为直接写Laoxiangji大概不方便阅读,而Home Original Chicken是china daily报道中所使用的老乡鸡的英文名,故简写成HOC。
|
至于为什么仓库名要叫CookLikeHOC,因为直接写Laoxiangji大概不方便阅读,而Home Original Chicken是china daily报道中所使用的老乡鸡的英文名,故简写成HOC。
|
||||||
|
|
||||||
|
|
||||||
## 本地开发
|
|
||||||
|
|
||||||
### 前置依赖
|
|
||||||
|
|
||||||
在开始之前,请确保你的开发环境中安装了 [Node.js](https://nodejs.org/) (推荐 v18.x 或更高版本)。
|
|
||||||
|
|
||||||
- **Windows:**
|
|
||||||
|
|
||||||
可以从 [Node.js 官网](https://nodejs.org/en/download/) 下载安装包进行安装。
|
|
||||||
或者使用包管理器 [Chocolatey](https://chocolatey.org/):
|
|
||||||
```bash
|
|
||||||
choco install nodejs
|
|
||||||
```
|
|
||||||
|
|
||||||
- **macOS:**
|
|
||||||
|
|
||||||
可以从 [Node.js 官网](https://nodejs.org/en/download/) 下载安装包进行安装。
|
|
||||||
或者使用包管理器 [Homebrew](https://brew.sh/):
|
|
||||||
```bash
|
|
||||||
brew install node
|
|
||||||
```
|
|
||||||
|
|
||||||
- **Linux:**
|
|
||||||
|
|
||||||
对于 Debian/Ubuntu 系统,可以使用 [NodeSource](https://github.com/nodesource/distributions) 来安装:
|
|
||||||
```bash
|
|
||||||
curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash -
|
|
||||||
sudo apt-get install -y nodejs
|
|
||||||
```
|
|
||||||
|
|
||||||
对于 RHEL/CentOS 系统:
|
|
||||||
```bash
|
|
||||||
curl -fsSL https://rpm.nodesource.com/setup_18.x | sudo bash -
|
|
||||||
sudo yum install -y nodejs
|
|
||||||
```
|
|
||||||
|
|
||||||
### 启动项目
|
|
||||||
|
|
||||||
1. 克隆代码仓库
|
|
||||||
|
|
||||||
```bash
|
|
||||||
git clone https://github.com/Gar-b-age/CookLikeHOC.git
|
|
||||||
```
|
|
||||||
|
|
||||||
2. 进入项目目录
|
|
||||||
|
|
||||||
```bash
|
|
||||||
cd CookLikeHOC
|
|
||||||
```
|
|
||||||
|
|
||||||
3. 安装依赖
|
|
||||||
|
|
||||||
```bash
|
|
||||||
npm install
|
|
||||||
```
|
|
||||||
|
|
||||||
4. 运行
|
|
||||||
|
|
||||||
```bash
|
|
||||||
npm run docs:dev
|
|
||||||
```
|
|
||||||
|
|
||||||
然后打开浏览器,访问 http://localhost:5173/ 即可。
|
|
||||||
|
|
||||||
## Contributor
|
## Contributor
|
||||||
|
|
||||||

|

|
||||||
@@ -102,4 +44,4 @@
|
|||||||
|
|
||||||
## Star History
|
## Star History
|
||||||
|
|
||||||
[](https://star-history.com/#Gar-b-age/CookLikeHOC&Date)
|
[](https://star-history.com/#Gar-b-age/CookLikeHOC&Date)
|
||||||
63
docs/development.md
Normal file
63
docs/development.md
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
# 本地开发
|
||||||
|
|
||||||
|
### 前置依赖
|
||||||
|
|
||||||
|
在开始之前,请确保你的开发环境中安装了 [Node.js](https://nodejs.org/) (推荐 v18.x 或更高版本)。
|
||||||
|
|
||||||
|
- **Windows:**
|
||||||
|
|
||||||
|
可以从 [Node.js 官网](https://nodejs.org/en/download/) 下载安装包进行安装。
|
||||||
|
或者使用包管理器 [Chocolatey](https://chocolatey.org/):
|
||||||
|
```bash
|
||||||
|
choco install nodejs
|
||||||
|
```
|
||||||
|
|
||||||
|
- **macOS:**
|
||||||
|
|
||||||
|
可以从 [Node.js 官网](https://nodejs.org/en/download/) 下载安装包进行安装。
|
||||||
|
或者使用包管理器 [Homebrew](https://brew.sh/):
|
||||||
|
```bash
|
||||||
|
brew install node
|
||||||
|
```
|
||||||
|
|
||||||
|
- **Linux:**
|
||||||
|
|
||||||
|
对于 Debian/Ubuntu 系统,可以使用 [NodeSource](https://github.com/nodesource/distributions) 来安装:
|
||||||
|
```bash
|
||||||
|
curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash -
|
||||||
|
sudo apt-get install -y nodejs
|
||||||
|
```
|
||||||
|
|
||||||
|
对于 RHEL/CentOS 系统:
|
||||||
|
```bash
|
||||||
|
curl -fsSL https://rpm.nodesource.com/setup_18.x | sudo bash -
|
||||||
|
sudo yum install -y nodejs
|
||||||
|
```
|
||||||
|
|
||||||
|
### 启动项目
|
||||||
|
|
||||||
|
1. 克隆代码仓库
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/Gar-b-age/CookLikeHOC.git
|
||||||
|
```
|
||||||
|
|
||||||
|
2. 进入项目目录
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd CookLikeHOC
|
||||||
|
```
|
||||||
|
|
||||||
|
3. 安装依赖
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm install
|
||||||
|
```
|
||||||
|
|
||||||
|
4. 运行
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm run docs:dev
|
||||||
|
```
|
||||||
|
|
||||||
|
然后打开浏览器,访问 http://localhost:5173/ 即可。
|
||||||
Reference in New Issue
Block a user