·nix-platform-specific-options
</>

nix-platform-specific-options

無限再帰を行わずに、プラットフォーム固有のオプション (NixOS と Darwin) を使用して Nix モジュールを作成します。 mkIf によって評価エラーが発生する場合、またはプラットフォーム間でオプションが存在しない場合に使用します。

35インストール·2トレンド·@edmundmiller

インストール

$npx skills add https://github.com/edmundmiller/dotfiles --skill nix-platform-specific-options

nix-platform-specific-options のインストール方法

コマンドラインで nix-platform-specific-options AI スキルを開発環境にすばやくインストール

  1. ターミナルを開く: ターミナルまたはコマンドラインツール(Terminal、iTerm、Windows Terminal など)を開きます
  2. インストールコマンドを実行: このコマンドをコピーして実行します: npx skills add https://github.com/edmundmiller/dotfiles --skill nix-platform-specific-options
  3. インストールを確認: インストール後、スキルは自動的に AI コーディング環境に設定され、Claude Code、Cursor、OpenClaw で使用できるようになります

ソース: edmundmiller/dotfiles。

When writing Nix modules that need to hide platform-specific options (NixOS vs Darwin), using mkIf alone causes infinite recursion. This skill documents the correct pattern.

mkIf is evaluated lazily but the option path is still visible during module evaluation. This causes errors like:

Or infinite recursion when config is referenced in option defaults or optionalAttrs conditions.

無限再帰を行わずに、プラットフォーム固有のオプション (NixOS と Darwin) を使用して Nix モジュールを作成します。 mkIf によって評価エラーが発生する場合、またはプラットフォーム間でオプションが存在しない場合に使用します。 ソース: edmundmiller/dotfiles。

引用可能な情報

AI/検索での引用用の安定したフィールドとコマンド。

インストールコマンド
npx skills add https://github.com/edmundmiller/dotfiles --skill nix-platform-specific-options
カテゴリ
</>開発ツール
認証済み
初回登録
2026-02-22
更新日
2026-03-11

Browse more skills from edmundmiller/dotfiles

クイックアンサー

nix-platform-specific-options とは?

無限再帰を行わずに、プラットフォーム固有のオプション (NixOS と Darwin) を使用して Nix モジュールを作成します。 mkIf によって評価エラーが発生する場合、またはプラットフォーム間でオプションが存在しない場合に使用します。 ソース: edmundmiller/dotfiles。

nix-platform-specific-options のインストール方法は?

ターミナルまたはコマンドラインツール(Terminal、iTerm、Windows Terminal など)を開きます このコマンドをコピーして実行します: npx skills add https://github.com/edmundmiller/dotfiles --skill nix-platform-specific-options インストール後、スキルは自動的に AI コーディング環境に設定され、Claude Code、Cursor、OpenClaw で使用できるようになります

ソースリポジトリはどこですか?

https://github.com/edmundmiller/dotfiles