Skip to content
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
20 changes: 9 additions & 11 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -108,22 +108,20 @@ yarn-error.log*
.npm
.yarn-integrity

# TypeScript Server (exclude development builds, commit only production bundle)
Packages/src/TypeScriptServer~/dist/*
!Packages/src/TypeScriptServer~/dist/server.bundle.js
!Packages/src/TypeScriptServer~/dist/server.bundle.js.map

# Native Go CLI release artifacts are included in the Unity package
Packages/src/GoCli~/dist/*
!Packages/src/GoCli~/dist/darwin-arm64/
!Packages/src/GoCli~/dist/darwin-amd64/
!Packages/src/GoCli~/dist/windows-amd64/
!Packages/src/GoCli~/dist/darwin-arm64/uloop
!Packages/src/GoCli~/dist/darwin-amd64/uloop
!Packages/src/GoCli~/dist/windows-amd64/uloop.exe
!Packages/src/GoCli~/dist/darwin-arm64/uloop-launcher
!Packages/src/GoCli~/dist/darwin-amd64/uloop-launcher
!Packages/src/GoCli~/dist/windows-amd64/uloop-launcher.exe
Packages/src/GoCli~/dist/darwin-arm64/*
Packages/src/GoCli~/dist/darwin-amd64/*
Packages/src/GoCli~/dist/windows-amd64/*
!Packages/src/GoCli~/dist/darwin-arm64/uloop-core
!Packages/src/GoCli~/dist/darwin-arm64/uloop-dispatcher
!Packages/src/GoCli~/dist/darwin-amd64/uloop-core
!Packages/src/GoCli~/dist/darwin-amd64/uloop-dispatcher
!Packages/src/GoCli~/dist/windows-amd64/uloop-core.exe
!Packages/src/GoCli~/dist/windows-amd64/uloop-dispatcher.exe
Packages/src/GoCli~/release/

# Environment configuration files
Expand Down
394 changes: 386 additions & 8 deletions Assets/Tests/Editor/NativeCliInstallerTests.cs

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions Packages/src/Editor/CLI/CliConstants.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ public static class CliConstants
public const string SKILL_DIR_GLOB = "uloop-*";
public const string GO_CLI_PACKAGE_DIR_NAME = "GoCli~";
public const string DIST_DIR_NAME = "dist";
public const string GLOBAL_UNIX_COMMAND_NAME = EXECUTABLE_NAME;
public const string GLOBAL_WINDOWS_COMMAND_NAME = EXECUTABLE_NAME + ".exe";
public const string GLOBAL_DISPATCHER_UNIX_BUNDLE_NAME = "uloop-dispatcher";
public const string GLOBAL_DISPATCHER_WINDOWS_BUNDLE_NAME = "uloop-dispatcher.exe";
public const string LEGACY_NPM_PACKAGE_NAME = "uloop-cli";
public const string PROJECT_LOCAL_BIN_DIR_NAME = "bin";
public const string PROJECT_LOCAL_UNIX_COMMAND_NAME = "uloop-core";
public const string PROJECT_LOCAL_WINDOWS_COMMAND_NAME = "uloop-core.exe";
Expand Down
473 changes: 413 additions & 60 deletions Packages/src/Editor/CLI/NativeCliInstaller.cs

Large diffs are not rendered by default.

3 changes: 1 addition & 2 deletions Packages/src/Editor/UI/McpEditorWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -705,8 +705,7 @@ private async void HandleInstallCli()
{
CliInstallResult result = await NativeCliInstaller.InstallAsync(
Application.platform,
McpConstants.PackageInfo.version,
true);
McpConstants.PackageInfo.version);

if (!result.Success)
{
Expand Down
3 changes: 1 addition & 2 deletions Packages/src/Editor/UI/Setup/SetupWizardWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -806,8 +806,7 @@ private async void HandleInstallCli()
{
CliInstallResult result = await NativeCliInstaller.InstallAsync(
Application.platform,
McpConstants.PackageInfo.version,
true);
McpConstants.PackageInfo.version);

if (!result.Success)
{
Expand Down
13 changes: 8 additions & 5 deletions Packages/src/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,12 @@ Scope(s): io.github.hatayama.uloopmcp

## Step 1: Install the CLI

Install the global `uloop` launcher from terminal:
Select Window > Unity CLI Loop > Settings. A dedicated window will open. If the **CLI** button is not highlighted in blue, press **Install CLI**.

<details>
<summary>CLI-only terminal install</summary>

Use this only when you want to install the standalone global CLI without opening Unity package setup.

```bash
curl -fsSL https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.sh | sh
Expand All @@ -102,13 +107,11 @@ $env:ULOOP_REMOVE_LEGACY = "1"
irm https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.ps1 | iex
```

The **Install CLI** buttons in Settings and Setup Wizard use the same installer and opt into removing the legacy npm package automatically.

Select Window > Unity CLI Loop > Settings. A dedicated window will open — confirm that the **CLI** button is highlighted in blue.
</details>

<img width="277" height="306" alt="1" src="https://github.com/user-attachments/assets/0e25c327-73bf-4af6-997b-eebb3c26b372" />

The Settings window shows whether the global `uloop` command is detected. The distributed command is backed by the `uloop-dispatcher` binary, and the Unity package refreshes this project's `.uloop/bin/uloop-core` CLI bundle automatically when it is missing, version-mismatched, or binary-mismatched.
The Settings window shows whether the global `uloop` command is detected.



Expand Down
12 changes: 8 additions & 4 deletions Packages/src/README_ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,12 @@ Scope(s): io.github.hatayama.uloopmcp

## ステップ1: CLIのインストール

ターミナルからグローバルな `uloop` ランチャーをインストールします。
Window > Unity CLI Loop > Settingsを選択します。専用ウィンドウが開くので、**CLI** ボタンが青くなっていなければ **Install CLI** を押してください。

<details>
<summary>CLIだけをterminalからinstallする場合はこちら</summary>

Unity Package の setup を開かず、standalone の global CLI だけを入れたい場合に使ってください。

```bash
curl -fsSL https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.sh | sh
Expand All @@ -103,13 +108,12 @@ $env:ULOOP_REMOVE_LEGACY = "1"
irm https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.ps1 | iex
```

Settings と Setup Wizard の **Install CLI** ボタンは同じ installer を使い、旧 npm package の削除も自動で有効化します。
</details>

Window > Unity CLI Loop > Settingsを選択します。専用ウィンドウが開くので **CLI** ボタンが青くなっている事を確認します。

<img width="277" height="306" alt="1" src="https://github.com/user-attachments/assets/0e25c327-73bf-4af6-997b-eebb3c26b372" />

Settings ウィンドウでは、グローバルな `uloop` コマンドが検出されているかを確認できます。配布されるコマンドの実体は `uloop-dispatcher` binary で、このプロジェクト用の `.uloop/bin/uloop-core` CLI bundle は、未作成・バージョン不一致・binary 不一致のときに Unity Package が自動更新します。
Settings ウィンドウでは、グローバルな `uloop` コマンドが検出されているかを確認できます。



Expand Down
13 changes: 8 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,12 @@ Scope(s): io.github.hatayama.uloopmcp

## Step 1: Install the CLI

Install the global `uloop` launcher from terminal:
Select Window > Unity CLI Loop > Settings. A dedicated window will open. If the **CLI** button is not highlighted in blue, press **Install CLI**.

<details>
<summary>CLI-only terminal install</summary>

Use this only when you want to install the standalone global CLI without opening Unity package setup.

```bash
curl -fsSL https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.sh | sh
Expand All @@ -102,13 +107,11 @@ $env:ULOOP_REMOVE_LEGACY = "1"
irm https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.ps1 | iex
```

The **Install CLI** buttons in Settings and Setup Wizard use the same installer and opt into removing the legacy npm package automatically.

Select Window > Unity CLI Loop > Settings. A dedicated window will open — confirm that the **CLI** button is highlighted in blue.
</details>

<img width="277" height="306" alt="1" src="https://github.com/user-attachments/assets/0e25c327-73bf-4af6-997b-eebb3c26b372" />

The Settings window shows whether the global `uloop` command is detected. The distributed command is backed by the `uloop-dispatcher` binary, and the Unity package refreshes this project's `.uloop/bin/uloop-core` CLI bundle automatically when it is missing, version-mismatched, or binary-mismatched.
The Settings window shows whether the global `uloop` command is detected.



Expand Down
23 changes: 20 additions & 3 deletions README_ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,12 @@ Scope(s): io.github.hatayama.uloopmcp

## ステップ1: CLIのインストール

ターミナルからグローバルな `uloop` ランチャーをインストールします。
Window > Unity CLI Loop > Settingsを選択します。専用ウィンドウが開くので、**CLI** ボタンが青くなっていなければ **Install CLI** を押してください。

<details>
<summary>CLIだけをterminalからinstallする場合はこちら</summary>

Unity Package の setup を開かず、standalone の global CLI だけを入れたい場合に使ってください。

```bash
curl -fsSL https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.sh | sh
Expand All @@ -92,11 +97,23 @@ Windows PowerShell の場合:
irm https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.ps1 | iex
```

Window > Unity CLI Loop > Settingsを選択します。専用ウィンドウが開くので **CLI** ボタンが青くなっている事を確認します。
過去に npm 経由で TypeScript 版ランチャーを入れていた場合、installer は `uloop-cli` を検出しますが、デフォルトでは削除しません。インストール時に旧 npm package も削除する場合は、次のように実行してください。

```bash
curl -fsSL https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.sh | ULOOP_REMOVE_LEGACY=1 sh
```

```powershell
$env:ULOOP_REMOVE_LEGACY = "1"
irm https://raw.githubusercontent.com/hatayama/unity-cli-loop/main/scripts/install.ps1 | iex
```

</details>


<img width="277" height="306" alt="1" src="https://github.com/user-attachments/assets/0e25c327-73bf-4af6-997b-eebb3c26b372" />

Settings ウィンドウでは、グローバルな `uloop` コマンドが検出されているかを確認できます。配布されるコマンドの実体は `uloop-dispatcher` binary で、このプロジェクト用の `.uloop/bin/uloop-core` CLI bundle は、未作成・バージョン不一致・binary 不一致のときに Unity Package が自動更新します。
Settings ウィンドウでは、グローバルな `uloop` コマンドが検出されているかを確認できます。



Expand Down