# 自動重啟 server 工具

> 也有自己的 web 框架：<https://github.com/gin-gonic/gin>

類似於 nodemon 的 live-reload 工具。

<https://github.com/codegangsta/gin>

### 自訂 port

> 之後輸入 localhost:8081 會執行 port 8080 server

```
gin -p 8081 -a 8080
```

### 如果是用預設 port

預設 proxy 為 3001 指向 3000，所以 app 會佔用 3000，如果要存取 server 要存取 3001

如果安裝新模組要重新執行 gin


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://easonwang.gitbook.io/golang/di-san-fang-mo-zu/gin.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
