Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add Japanese README #219

Merged
merged 1 commit into from
Jul 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Thriftgo

English | [中文](README_cn.md)
English | [中文](README_cn.md) | [日本語](README_ja.md)

**Thriftgo** is an implementation of [thrift](https://thrift.apache.org/docs/idl) compiler in go language. It has a command line interface similar to the apache/thrift compiler and is enhanced with a plugin mechanism which makes it more powerful.

Expand Down
2 changes: 1 addition & 1 deletion README_cn.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Thriftgo

[English](README.md) | 中文
[English](README.md) | 中文 | [日本語](README_ja.md)

**Thriftgo** 是 go 语言实现的 thrift 编译器。它具有与 apache/thrift 编译器类似的命令行界面,并通过插件机制增强了功能,使其更加强大。

Expand Down
42 changes: 42 additions & 0 deletions README_ja.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Thriftgo

[英語](README.md) | [中文](README_cn.md) | 日本語

**Thriftgo** は、Go言語で実装された [thrift](https://thrift.apache.org/docs/idl) コンパイラです。apache/thrift コンパイラと似たコマンドラインインターフェースを持ち、プラグイン機構により強化されており、より強力です。

## インストール

注意: 以下のコマンドを実行する前に、**`GOPATH` 環境が正しく設定されていることを確認してください**。

`go install` を使用:

`GO111MODULE=on go install github.com/cloudwego/thriftgo@latest`

またはソースからビルド:

```shell
git clone https://github.com/cloudwego/thriftgo.git
cd thriftgo
export GO111MODULE=on
go mod tidy
go build
go install
```

## 使用方法

Thriftgo コマンドラインツールは IDL ファイルを受け取り、ターゲット言語にコンパイルします。各バックエンドには、生成されたコードをカスタマイズするための豊富なオプションが用意されています。

現時点では、Thriftgo は golang コードのみを生成できます。将来的には、他のバックエンドも追加される予定です。

デフォルト設定で thrift IDL を golang ファイルにコンパイルするには、次のコマンドを実行します:

```shell
thriftgo -g go the-idl-file.thrift
```

各バックエンドのすべての利用可能なオプションとその意味を確認するには、`thriftgo -h` を実行してください。

## プラグイン

Thriftgo が生成するコードがニーズを満たさず、提供されているオプションが要件を満たさない場合は、プラグインを作成して Thriftgo の IDL パーサーを利用して追加のコードを生成することができます。詳細については、プラグインパッケージのドキュメントを参照してください。
Loading