주제: PowerShell
홈으로-
AgentCLIHub Development Notes 2: Finding Installed CLIs on Windows
AI-generated illustration of Windows CLI path discovery. 한국어로 읽기 / Korean version This article explains the code at fixed commit 46dfca2, reviewed on October 17, 2026. It does not report runtime tests or performance measurements. codex can run in PowerShell while a GUI application on the same computer fails to find its executable. The two processes may have different PATH values and command-resolution environments. Agent CLI Hub’s discovery code determines both where a CLI is located and how to launch it. 1. Why a discovery result contains more than a path Alongside the executable path and discovery source, CliLocator.Result stores the Node executable, JavaScript entry point, PowerShell path, and whether to load a PowerShell profile. Even after locating a command, the launch method depends on whether it is a native program, an npm wrapper, or a function defined in a shell profile. For example, finding claude.cmd does not necessarily mean executing that file directly. If the asso...

-
AgentCLIHub 개발 노트 2: 설치돼 있는데 못 찾는 CLI, Windows 실행 경로 탐지
Windows CLI 경로 탐지 과정을 표현한 AI 생성 일러스트입니다. Read in English / 영문 버전 이 글은 2026년 10월 17일에 확인한 고정 커밋 46dfca2 기준의 코드 해설입니다. 실제 환경에서의 실행 시험이나 성능 측정 결과는 포함하지 않습니다. PowerShell에서는 codex 가 실행되는데 GUI 앱에서는 실행 파일을 찾지 못할 수 있습니다. 같은 컴퓨터에서도 두 프로세스가 보는 PATH와 명령 해석 환경이 다르기 때문입니다. Agent CLI Hub의 탐지 코드는 파일 위치뿐 아니라 어떤 경로로 실행해야 하는지도 함께 구합니다. 1. 탐지 결과에 경로만 담지 않는 이유 CliLocator.Result 에는 실행 경로와 발견 출처 외에 Node 실행 파일, JavaScript 진입점, PowerShell 경로, 프로필 사용 여부가 들어 있습니다. 실행 대상을 찾은 다음에도 네이티브 프로그램인지, npm 래퍼인지, 셸 프로필의 함수인지에 따라 시작 방식이 달라지기 때문입니다. 예를 들어 claude.cmd 를 찾았다고 해서 그 파일을 반드시 그대로 실행하는 것은 아닙니다. 연결된 JavaScript 진입점과 Node를 찾으면 두 경로로 명령의 앞부분을 만듭니다. PowerShell 함수로 등록된 CLI라면 명령 이름과 프로필을 사용하는 셸 정보가 결과가 됩니다. 따라서 Found 는 탐지 결과가 있다는 의미로 읽어야 합니다. 실제 실행 성공이나 로그인 완료까지 증명하는 값은 아닙니다. 탐지와 기동을 구분하면 “파일을 못 찾았다”와 “찾았지만 시작하지 못했다”를 다른 단계에서 다룰 수 있습니다. 탐지 결과와 실행 명령 2. 우선순위를 먼저 정한다 탐지의 출발점은 사용자가 설정한 경로입니다. 환경변수를 펼치고 경로를 정규화한 뒤 파일이 존재하면 이 값을 사용합니다. 지정 경로가 유효하지 않으면 자동 탐색을 계속합니다. 그다음 순서는 CLI에 따라 다릅니다. Codex는 먼저 PowerShell의 Get-Command...
