File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -22,6 +22,8 @@ Qiita の Markdown 記法については[Markdown 記法 チートシート](htt
22
22
23
23
Qiita CLI を使うには ` Node.js 18.0.0 ` 以上が必要です。Node.js をはじめて使う場合はインストールする必要があります。
24
24
25
+ > ` Docker ` で利用するには` Docker ` がインストールされている必要があります。
26
+
25
27
### 2. Qiita CLI をインストールする
26
28
27
29
Qiita のコンテンツを管理したいディレクトリで、以下のコマンドを実行します。
@@ -30,6 +32,12 @@ Qiita のコンテンツを管理したいディレクトリで、以下のコ
30
32
npm install @qiita/qiita-cli --save-dev
31
33
```
32
34
35
+ > ` Docker ` で環境を構築する場合は次のコマンドで実行できます。
36
+ >
37
+ > ``` console
38
+ >docker run --rm -v $(pwd):/opt -w /opt node:20-alpine3.17 sh -c "npm install @qiita/qiita-cli --save-dev && npx qiita init"
39
+ >```
40
+
33
41
以下のコマンドでバージョンが表示されればインストール完了です。
34
42
35
43
```console
@@ -51,13 +59,21 @@ npm install @qiita/qiita-cli@latest
51
59
以下のコマンドを実行することで、
52
60
53
61
- .gitignore
62
+ - Dockerfile
63
+ - docker-compose.yml
54
64
- GitHub Actions のワークフローファイル
55
65
- 「GitHub で記事を管理する」の項目を参照
56
66
- ユーザー設定ファイル(qiita.config.json)
57
67
- 「ユーザー設定ファイルについて」の項目を参照
58
68
59
69
が生成されます。
60
70
71
+ > ` Docker ` で環境を構築する場合はコンテナを起動してから実行してください。
72
+ >
73
+ > ``` console
74
+ >docker-compose up -d && docker-compose exec qiita sh
75
+ >```
76
+
61
77
```console
62
78
npx qiita init
63
79
```
You can’t perform that action at this time.
0 commit comments