Skip to content

Commit

Permalink
fbi命令名字修改
Browse files Browse the repository at this point in the history
  • Loading branch information
funnyli committed Sep 10, 2020
1 parent af02955 commit 618a9ea
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 25 deletions.
2 changes: 0 additions & 2 deletions docs/pages/4x/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,3 @@ github: <https://github.com/fbi-js/fbi>

- nodejs >= 12.x
- npm >= 6.x

> 为了避免与 3.x 版本的冲突,4.x 版本命令修改为 fbi-next
34 changes: 17 additions & 17 deletions docs/pages/4x/advance.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
查看已添加的仓库及模板信息

```
$ fbi-next ls/list [factory] [flags]
$ fbi ls/list [factory] [flags]
```

**factory**
Expand All @@ -16,7 +16,7 @@ $ fbi-next ls/list [factory] [flags]
**例子**

```
$ fbi-next ls factory-web
$ fbi ls factory-web
```

**flags**
Expand All @@ -30,16 +30,16 @@ $ fbi-next ls factory-web
**例子**

```
$ fbi-next ls -a
$ fbi-next ls -v
$ fbi ls -a
$ fbi ls -v
```

## 模板管理

### 通过远程仓库添加

```
$ fbi-next add <remote repositories...>
$ fbi add <remote repositories...>
```

**remote repositories**
Expand All @@ -50,22 +50,22 @@ $ fbi-next add <remote repositories...>
- 例子:

```
$ fbi-next add https://github.com/fbi-js/factory-web
$ fbi add https://github.com/fbi-js/factory-web
```

### 添加本地模板

```
$ cd local-factory // 切到本地要link的仓库目录下
$ fbi-next link
$ fbi link
$ cd .. // 切出当前仓库目录
$ fbi-next ls // 查看仓库是否关联成功
$ fbi ls // 查看仓库是否关联成功
```

### 解除本地模板链接

```
$ fbi-next unlink [factory]
$ fbi unlink [factory]
```

**factory**
Expand All @@ -80,15 +80,15 @@ $ fbi unlink factory-web
# OR
$ cd factory-web // 先切换到需要unlink的仓库目录下
$ fbi-next unlink
$ fbi unlink
```

### 移除模板

解除模板与 fbi 的链接并移除模板的本地文件

```
$ fbi-next remove <repositorie name>
$ fbi remove <repositorie name>
```

**repositorie name**
Expand All @@ -99,7 +99,7 @@ $ fbi-next remove <repositorie name>
- 例子:

```
$ fbi-next remove factory-web
$ fbi remove factory-web
```

## 项目管理
Expand All @@ -118,7 +118,7 @@ $ fbi create <template> [-p]
- 例子:

```shell
$ fbi-next create web
$ fbi create web
```

**-p**
Expand All @@ -128,15 +128,15 @@ $ fbi-next create web
- 例子:

```shell
$ fbi-next create web -p yarn
$ fbi create web -p yarn
```

## 其他命令

```bash
$ fbi-next info // 查看context信息
$ fbi-next -v/--version
$ fbi-next -h/--help
$ fbi info // 查看context信息
$ fbi -v/--version
$ fbi -h/--help
```

## 模板开发
Expand Down
12 changes: 6 additions & 6 deletions docs/pages/4x/entry.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,27 +17,27 @@ $ pnpm i -g fbi@next
### 一、基于远程仓库添加 fbi 模板

```
$ fbi-next add <remote repositories...>
$ fbi add <remote repositories...>
```

> 查看更多官方模板:[官方模板列表](/pages/4x/more.md)
### 二、通过添加的模板创建项目

```bash
$ fbi-next create <tempalate name>
$ fbi create <tempalate name>
```

> 使用 `$ fbi-next ls` 可以查看已添加和关联的仓库及模板
> 使用 `$ fbi ls` 可以查看已添加和关联的仓库及模板
### 三、运行任务

```shell
$ cd my-project

$ fbi-next serve
$ fbi serve
# OR
$ fbi-next s
$ fbi s
```

> `$ fbi-next ls` 可查看当前目录可用的任务和模板
> `$ fbi ls` 可查看当前目录可用的任务和模板

0 comments on commit 618a9ea

Please sign in to comment.