コマンドひとつで、ウインドウを自在に
Betaウインドウの確認も、レイアウトの配置もターミナルから。デスクトップの操作をスクリプトやAIのワークフローに組み込めます。
コマンドをインストールtangrid windows --desktop current| ID | APP |
|---|---|
| visual-studio-code1 | Visual Studio Code |
| safari1 | Safari |
tangrid mode flow
tangrid flow arrange --desktop current \
--windows visual-studio-code1,safari1 \
--style columnstangrid mode flow
tangrid flow group create \
--windows visual-studio-code1,safari1 \
--active visual-studio-code1IDは例です。お使いのMacでtangrid windowsが返すIDを使用してください。
FlowとSnap、使い方に合わせて
Flowはウインドウを整列。Snapは一度だけ配置し、その後は自由に動かせます。モードはコマンドで切り替えます。
Flowレイアウトを継続して自動調整
tangrid mode flow
tangrid flow arrange --desktop current \
--all-eligible --style columnsSnap一度配置した後は自由に操作
tangrid mode snap
tangrid snap arrange --desktop current \
--all-eligible --style columnsレイアウトをファイルに
分割とタブグループをJSONで定義。--dry-runで確認してから適用できます。Tangridがウインドウのサイズと位置を計算します。
{
"apiVersion": 1,
"desktopId": "desktop1",
"unlisted": "error",
"layout": {
"type": "split",
"orientation": "columns",
"children": [
{ "type": "window", "windowId": "visual-studio-code1" },
{ "type": "window", "windowId": "safari1" }
]
}
}tangrid flow apply --file layout.json --dry-run
tangrid flow apply --file layout.jsonAIエージェントでデスクトップを操作
ローカルのshellにアクセスできるエージェントは、ウインドウの状態と利用可能なコマンドを確認し、配置を変更できます。JSON出力とプレビューで、実行前に変更内容を確認できます。
スキルをインストール
https://tangrid.app/SKILL.mdからTangridスキルをインストールしてください。
SKILL.mdコピーしました
使用例
現在のデスクトップのウインドウを均等に配置して。
tangrid state --json
tangrid capabilities --json
tangrid mode flow
tangrid flow balance --desktop current --jsonTangridで準備、ターミナルで操作
BetaTangridを開く
ウインドウの状態を取得・変更するときは、アプリを起動したままにしてください。
コマンドをインストール
設定の「Window Manager → CLI」で「Install CLI」を選びます。
最初のコマンドを実行
準備状態とウインドウ一覧を確認し、内蔵ヘルプでほかのコマンドを調べます。
tangrid status
tangrid windows
tangrid --help同梱の実行ファイルを直接使う
Tangridが/Applicationsにある場合は、同梱CLIを直接実行するかPATHに追加できます。ほかの場所にある場合はパスを変更してください。
/Applications/Tangrid.app/Contents/CLI/tangrid --helpexport PATH="/Applications/Tangrid.app/Contents/CLI:$PATH"exportの行を~/.zshrcに追加すると、次回以降のターミナルでも使用できます。
コマンドリファレンス
W = ウインドウ、G = Flowグループ、D = デスクトップ、M = ディスプレイ。角括弧は省略可能な引数、| は選択肢の区切りを表します。
共通コマンド
| コマンド | 引数 | 用途 |
|---|---|---|
tangrid status | なし | アプリのバージョン、モード、準備状態、処理中かどうかを確認します。 |
tangrid capabilities | [--window W] | 利用可能なコマンド、データ構造、制約を一覧表示します。 |
tangrid state | [--desktop D] [--display M] | ウインドウ、ディスプレイ、デスクトップ、レイアウト、リビジョンのスナップショットを取得します。 |
tangrid windows | [--desktop D] [--display M] [--app BUNDLE_ID] [--title-contains TEXT] [--title-regex REGEX] [--placement tiled|floating|unmanaged] [--focused] | 指定した条件に一致するウインドウを一覧表示します。 |
tangrid window W | なし | 1つのウインドウの状態をすべて取得します。 |
tangrid displays | なし | ディスプレイ、位置とサイズ、拡大率、アクティブなデスクトップを一覧表示します。 |
tangrid desktops | [--display M] [--include-fullscreen] | デスクトップを一覧表示します。標準のフルスクリーン用Spaceも含められます。 |
tangrid mode | [flow|snap|off] | アプリ全体で保存されるモードを確認・変更します。 |
tangrid focus W | なし | ウインドウを復元してフォーカスし、必要に応じてFlowタブを選択します。 |
tangrid focus | --from W --direction left|right|up|down | 指定方向に隣接するウインドウにフォーカスします。 |
tangrid move W | (--display M | --desktop D) [--follow] | ウインドウをディスプレイやデスクトップに移動します。移動先への切り替えも選べます。 |
tangrid resize W | --direction grow|shrink [--steps N] | 設定された変更幅と現在のモードの制約に従ってサイズを変更します。 |
tangrid fill-screen W | --enabled true|false | 現在のデスクトップ内でFill Screenを有効・無効にします。 |
tangrid fullscreen W | --enabled true|false | macOS標準のフルスクリーンを開始・終了します。 |
tangrid minimize W | --enabled true|false | ウインドウを最小化・復元します。 |
tangrid close W | なし | ウインドウを閉じるよう要求します。 |
tangrid watch | [--events window,desktop,display,layout,group,mode] [--desktop D] | ウインドウ、デスクトップ、ディスプレイ、レイアウト、グループ、モードの変更を監視します。 |
tangrid operation ID | なし | 受け付け済みの変更を操作IDで確認します。 |
tangrid operation | --request-id UUID | 呼び出し側が指定したリクエストIDで変更を確認します。 |
tangrid --help | なし | アプリを起動せずにヘルプを表示します。 |
tangrid --version | なし | アプリを起動せずにCLIのバージョンを表示します。 |
Flowコマンド
| コマンド | 引数 | 用途 |
|---|---|---|
tangrid flow layout | --desktop D | デスクトップのレイアウト関係を取得します。 |
tangrid flow tile | --windows W1,W2 | ウインドウをFlowの継続管理に戻します。有効な復帰位置を優先します。 |
tangrid flow float | --windows W1,W2 | 指定したウインドウをフローティングにします。 |
tangrid flow arrange | (--windows W1,W2 [--desktop D] | --desktop D --all-eligible) --style auto|columns|rows | 選択したウインドウを集めて配置し、Flowで継続管理します。 |
tangrid flow place | --target W_OR_G --relative-to W_OR_G --side left|right|up|down | 既存のレイアウト領域の隣にウインドウやグループを挿入します。 |
tangrid flow swap | --first W_OR_G --second W_OR_G | 同じデスクトップ上の2つのウインドウやグループを入れ替えます。 |
tangrid flow balance | --desktop D | ウインドウのサイズ制約内でスペースを均等に配分します。 |
tangrid flow rotate | --desktop D --direction clockwise|counterclockwise | デスクトップのレイアウトを回転します。 |
tangrid flow flip | --around W_OR_G | 直近の親分割を現在の方向に沿って反転します。 |
tangrid flow orient | --around W_OR_G --orientation columns|rows | 直近の親分割を横並びまたは縦並びに設定します。 |
tangrid flow apply | --file FILE | --stdin | デスクトップ全体に宣言的レイアウトを適用します。 |
Flowタブグループ
| コマンド | 引数 | 用途 |
|---|---|---|
tangrid flow group list | [--desktop D] | Flowタブグループを一覧表示します。 |
tangrid flow group get G | なし | メンバー、タブ順、アクティブなタブ、レイアウト領域を取得します。 |
tangrid flow group create | --windows W1,W2 [--active W1] [--anchor W1] | 2つ以上のウインドウからタブグループを作成します。 |
tangrid flow group add G | --windows W3,W4 | 指定したウインドウをグループに追加します。 |
tangrid flow group remove G | --windows W2 [--placement tiled|floating] | メンバーを取り出します。既定では独立したタイル配置に戻します。 |
tangrid flow group reorder G | --windows W2,W1,W3 | グループ全体のタブ順を設定します。 |
tangrid flow group dissolve G | [--placement tiled|floating] | メンバーを個別の配置に戻します。既定はタイル配置です。 |
tangrid flow group move G | (--display M | --desktop D) [--follow] | グループ全体をディスプレイやデスクトップに移動します。移動先への切り替えも選べます。 |
Snapコマンド
| コマンド | 引数 | 用途 |
|---|---|---|
tangrid snap layout | --desktop D | 現在の位置とサイズ、スナップ関係を取得します。 |
tangrid snap arrange | (--windows W1,W2 [--desktop D] | --desktop D --all-eligible) --style auto|columns|rows | ウインドウを集めて一度配置し、その後のスナップに参加させます。 |
tangrid snap place | --window W --relative-to W2 --side left|right|up|down | 別のウインドウを基準に分割配置します。 |
tangrid snap place | --window W --edge left|right | 現在の位置とサイズに基づき、ディスプレイの端に配置します。 |
tangrid snap set-floating | --windows W1,W2 --enabled true|false | 現在の位置とサイズを保ったまま、スナップからの除外を設定します。 |
tangrid snap apply | --file FILE | --stdin | 宣言的レイアウトを一度だけ適用します。 |
Macのウィンドウ管理を、もっと快適に。
Tangridを7日間無料でお試しください。買い切りで、購入後14日以内の返金保証付き。