From dc4aceeec4b50af2c280bb22c1870690c8e741a4 Mon Sep 17 00:00:00 2001 From: Jerry Chae Date: Tue, 2 Jun 2026 11:35:41 +0900 Subject: [PATCH] =?UTF-8?q?codex=20cli=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 36 +++++++++++++++++++++- install-codex-cli.ps1 | 71 +++++++++++++++++++++++++++++++++++++++++++ install-codex-cli.sh | 44 +++++++++++++++++++++++++++ 3 files changed, 150 insertions(+), 1 deletion(-) create mode 100644 install-codex-cli.ps1 create mode 100644 install-codex-cli.sh diff --git a/README.md b/README.md index 58a1c05..034fcec 100644 --- a/README.md +++ b/README.md @@ -25,6 +25,7 @@ ### πŸ€– 4. AI 개발 μ—μ΄μ „νŠΈ (AI Agents) * **[Antigravity CLI (agy)](https://antigravity.google)** - Antigravity 2.0 ν”Œλž«νΌμ˜ κ²½λŸ‰ν™” 터미널 μ½”λ”© μ—μ΄μ „νŠΈ CLI * **[Claude Code](https://code.claude.com/)** - Anthropic의 μ°¨μ„ΈλŒ€ 터미널 기반 λŒ€ν™”ν˜• AI μ½”λ”© μ–΄μ‹œμŠ€ν„΄νŠΈ CLI +* **[Codex CLI](https://developers.openai.com/codex/cli)** - OpenAI의 곡식 터미널 기반 둜컬 λŒ€ν™”ν˜• μ½”λ”© μ—μ΄μ „νŠΈ CLI * **[pi](https://pi.dev/)** - λŒ€ν™”ν˜• CLI AI μ½”λ”© μ–΄μ‹œμŠ€ν„΄νŠΈ 및 μΆ”μ²œ ν”ŒλŸ¬κ·ΈμΈ νŒ¨ν‚€μ§€ 일괄 μ„€μΉ˜ 도ꡬ --- @@ -106,6 +107,11 @@ curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-claude-code.sh?ref_type=heads" | bash ``` +* **Codex CLI:** + ```bash + curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-codex-cli.sh?ref_type=heads" | bash + ``` + * **pi (Pi Coding Agent + μΆ”μ²œ νŒ¨ν‚€μ§€):** ```bash curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-pi.sh?ref_type=heads" | bash @@ -242,6 +248,16 @@ $t="$env:TEMP\install-claude-code.ps1"; iwr -useb 'https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-claude-code.ps1' -OutFile $t; powershell -ExecutionPolicy Bypass -File $t ``` +* **Codex CLI:** + * **CMD μ°½μ—μ„œ μ„€μΉ˜ μ‹œ:** + ```cmd + powershell -ExecutionPolicy Bypass -c "[Net.ServicePointManager]::SecurityProtocol=[Net.SecurityProtocolType]::Tls12; $t=\"$env:TEMP\install-codex-cli.ps1\"; iwr -useb 'https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-codex-cli.ps1' -OutFile $t; & $t" + ``` + * **νŒŒμ›Œμ‰˜ μ°½μ—μ„œ μ„€μΉ˜ μ‹œ:** + ```powershell + $t="$env:TEMP\install-codex-cli.ps1"; iwr -useb 'https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-codex-cli.ps1' -OutFile $t; powershell -ExecutionPolicy Bypass -File $t + ``` + * **pi (Pi Coding Agent + μΆ”μ²œ νŒ¨ν‚€μ§€):** * **CMD μ°½μ—μ„œ μ„€μΉ˜ μ‹œ:** ```cmd @@ -498,7 +514,25 @@ claude -p "질문/μž‘μ—…" # 터미널 창을 μ—΄μ§€ μ•Šκ³  μ¦‰μ‹œ μ§€μ‹œ 수 claude --help # 도움말 및 μ‚¬μš©λ²• λ‘œλ“œ ``` -#### 4.3. Pi Coding Agent +#### 4.3. Codex CLI +OpenAIμ‚¬μ—μ„œ κ°œλ°œν•œ 곡식 터미널 기반 λŒ€ν™”ν˜• 둜컬 μ½”λ”© μ—μ΄μ „νŠΈ CLIμž…λ‹ˆλ‹€. Rust 기반으둜 μ œμž‘λ˜μ–΄ 높은 μ„±λŠ₯을 μžλž‘ν•˜λ©°, npm 없이도 단일 μ‹€ν–‰(curl) 및 PowerShell(Windows) 곡식 μΈμŠ€ν†¨λŸ¬ 방식을 ν™œμš©ν•΄ λ„€μ΄ν‹°λΈŒν•˜κ²Œ μž‘λ™ κ°€λŠ₯ν•©λ‹ˆλ‹€. + +* **κ°•λ ₯ν•œ μ‹œμŠ€ν…œ 톡합** β€” 터미널 둜컬 ν™˜κ²½μ—μ„œ μ‚¬μš©μžμ˜ μ§€μ‹œ ν•˜μ— 파일 νŽΈμ§‘, μ•„ν‚€ν…μ²˜ λ¦¬μ„œμΉ˜ 및 CLI λΉŒλ“œ μ‹€ν–‰ 지원 +* **λ‹€μ–‘ν•œ λͺ¨λΈ μŠ€μ™‘** β€” μ„Έμ…˜ λ‚΄μ—μ„œ GPT-5.4, GPT-5.3-Codex λ“±μœΌλ‘œ 자유둭게 λ‘λ‡Œ λ³€κ²½ 및 μΆ”λ‘  μ‘°μž‘ 지원 +* **λ©€ν‹°λͺ¨λ‹¬ μ‹œκ° 뢄석** β€” μŠ€ν¬λ¦°μƒ·μ΄λ‚˜ μ™€μ΄μ–΄ν”„λ ˆμž„ 섀계도λ₯Ό μž…λ ₯λ°›μ•„ UI μ½”λ“œλ₯Ό κ³ μ†μœΌλ‘œ κ΅¬ν˜„ 및 ν”Όλ“œλ°± + +```bash +codex # 가동 λͺ…λ Ήμ–΄ +``` + +##### [Codex CLI κΈ°λ³Έ μ‚¬μš©λ²•] +```bash +codex auth # OpenAI ChatGPT λ˜λŠ” API 계정 연동 둜그인 +codex # λŒ€ν™”ν˜• μ½”λ”© TUI μ„Έμ…˜ μ‹œμž‘ +codex -p "μž‘μ—…λͺ…λ Ή" # 둜컬 파일 μ‹œμŠ€ν…œ λ³€κ²½ 및 λΉŒλ“œ 직접 μ§€μ‹œ (λ‹¨λ°œ) +``` + +#### 4.4. Pi Coding Agent CLI 기반의 μ΅œμ²¨λ‹¨ AI μ½”λ”© νŒŒνŠΈλ„ˆμž…λ‹ˆλ‹€. λ³Έ μ €μž₯μ†Œμ˜ `install-pi` μ„€μΉ˜ 도ꡬλ₯Ό ν™œμš©ν•˜λ©΄ μ—μ΄μ „νŠΈ 본체뿐 μ•„λ‹ˆλΌ μ„±λŠ₯ κ·ΉλŒ€ν™”λ₯Ό μ§€μ›ν•˜λŠ” 핡심 ν”ŒλŸ¬κ·ΈμΈ μ—μ½”μ‹œμŠ€ν…œ 15쒅을 λ‹¨λ²ˆμ— 일괄 μ…‹μ—…ν•  수 μžˆμŠ΅λ‹ˆλ‹€. ##### [일괄 μ„€μΉ˜λ˜λŠ” μΆ”μ²œ νŒ¨ν‚€μ§€ 리슀트] diff --git a/install-codex-cli.ps1 b/install-codex-cli.ps1 new file mode 100644 index 0000000..9645ddc --- /dev/null +++ b/install-codex-cli.ps1 @@ -0,0 +1,71 @@ +#Requires -Version 5.1 +<# +.SYNOPSIS + Installs OpenAI Codex CLI on Windows using PowerShell. + +.DESCRIPTION + Installs OpenAI Codex CLI natively by invoking the official install.ps1 script. + This native installation method is recommended for Windows. + Official Guide: https://developers.openai.com/codex/cli + +.EXAMPLE + .\install-codex-cli.ps1 + + # One-liner install from remote (works on Windows 10+): + powershell -ExecutionPolicy Bypass -c "[Net.ServicePointManager]::SecurityProtocol=[Net.SecurityProtocolType]::Tls12; $t=\"$env:TEMP\install-codex-cli.ps1\"; iwr -useb 'https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-codex-cli.ps1' -OutFile $t; & $t" + +.NOTES + If execution policy error occurs: + Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser +#> + +[CmdletBinding()] +param() + +# μ΅œμ‹  μœˆλ„μš° ν™˜κ²½ 및 μ—λŸ¬ λ°œμƒ μ‹œ μ¦‰μ‹œ 쀑단 μ„€μ • +Set-StrictMode -Version Latest +$ErrorActionPreference = 'Stop' + +# HTTPS λ‹€μš΄λ‘œλ“œλ₯Ό μœ„ν•œ TLS 1.2 κ°•μ œ (PowerShell 5.1 ν˜Έν™˜μ„± 보μž₯) +[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 + +# ──────────────────────────────────────────── +# μœ ν‹Έλ¦¬ν‹° ν•¨μˆ˜ μ •μ˜ (λͺ¨λ“  μ•ˆλ‚΄ λ¬Έκ΅¬λŠ” 영문으둜 μž‘μ„±) +# ──────────────────────────────────────────── +function Write-Info { param([string]$msg) Write-Host "[INFO] $msg" -ForegroundColor Cyan } + # 정보 좜λ ₯ +function Write-Warn { param([string]$msg) Write-Host "[WARN] $msg" -ForegroundColor Yellow } + # κ²½κ³  좜λ ₯ +function Write-Success { param([string]$msg) Write-Host "[OK] $msg" -ForegroundColor Green } + # 성곡 좜λ ₯ +function Write-Err { param([string]$msg) Write-Host "[ERROR] $msg" -ForegroundColor Red; exit 1 } + # μ—λŸ¬ 좜λ ₯ 및 슀크립트 κ°•μ œ μ’…λ£Œ + +# ──────────────────────────────────────────── +# 메인 μ„€μΉ˜ ν”„λ‘œμ„ΈμŠ€ +# ──────────────────────────────────────────── +function Main { + Write-Info "===== Codex CLI install script (Windows PowerShell) =====" + Write-Info "Installing OpenAI Codex CLI natively..." + + try { + Write-Info "Fetching and executing official installer from: https://chatgpt.com/codex/install.ps1" + + # 곡식 μ„€μΉ˜ ps1 슀크립트λ₯Ό λ‹€μš΄λ‘œλ“œ 및 λ©”λͺ¨λ¦¬ μƒμ—μ„œ 직접 호좜 가동 + $installerScript = Invoke-RestMethod -Uri "https://chatgpt.com/codex/install.ps1" -UseBasicParsing + Invoke-Expression $installerScript + + Write-Success "Codex CLI has been successfully installed!" + Write-Info "Please restart your terminal window or refresh your PATH environment variable." + Write-Info "Run command: codex auth (to log in) and then 'codex' to start." + } catch { + Write-Err "Failed to install Codex CLI: $_" + } +} + +# 예기치 λͺ»ν•œ 전체 ν”„λ‘œμ„ΈμŠ€ μ—λŸ¬ 감지λ₯Ό μœ„ν•œ Trap μ„€μ • +trap { + Write-Err "An unexpected error occurred during installation: $_" +} + +Main diff --git a/install-codex-cli.sh b/install-codex-cli.sh new file mode 100644 index 0000000..c473fe4 --- /dev/null +++ b/install-codex-cli.sh @@ -0,0 +1,44 @@ +#!/usr/bin/env bash +# shellcheck disable=SC2086 + +# OpenAI Codex CLI λ„€μ΄ν‹°λΈŒ μ„€μΉ˜ 슀크립트 +# +# macOS, Linux ν™˜κ²½μ—μ„œ curl을 μ‚¬μš©ν•˜μ—¬ 곡식 μ„€μΉ˜ 슀크립트λ₯Ό λ‹€μš΄λ‘œλ“œν•˜κ³  sh둜 μ‹€ν–‰ν•©λ‹ˆλ‹€. +# 곡식 κ°€μ΄λ“œ: https://developers.openai.com/codex/cli + +set -euo pipefail + +# ──────────────────────────────────────────── +# μœ ν‹Έλ¦¬ν‹° ν•¨μˆ˜ (λͺ¨λ‘ stderr 좜λ ₯) +# ──────────────────────────────────────────── +info() { echo "[INFO] $*" >&2; } +warn() { echo "[WARN] $*" >&2; } +error() { echo "[ERROR] $*" >&2; exit 1; } +success() { echo "[OK] $*" >&2; } + +# ──────────────────────────────────────────── +# ν•„μˆ˜ λͺ…λ Ήμ–΄ 확인 +# ──────────────────────────────────────────── +if ! command -v curl &>/dev/null; then + error "'curl' λͺ…λ Ήμ–΄κ°€ ν•„μš”ν•©λ‹ˆλ‹€. λ¨Όμ € μ„€μΉ˜ν•΄ μ£Όμ„Έμš”." +fi + +# ──────────────────────────────────────────── +# 메인 μ„€μΉ˜ 둜직 +# ──────────────────────────────────────────── +main() { + info "OpenAI Codex CLI λ„€μ΄ν‹°λΈŒ μ„€μΉ˜λ₯Ό μ‹œμž‘ν•©λ‹ˆλ‹€..." + info "곡식 μ„€μΉ˜ 슀크립트 μ‹€ν–‰ 쀑: curl -fsSL https://chatgpt.com/codex/install.sh | sh" + + # OpenAI 곡식 슀크립트 호좜 μ‹€ν–‰ + if curl -fsSL https://chatgpt.com/codex/install.sh | sh; then + success "Codex CLI μ„€μΉ˜κ°€ μ„±κ³΅μ μœΌλ‘œ μ™„λ£Œλ˜μ—ˆμŠ΅λ‹ˆλ‹€!" + info "μƒˆλ‘œμš΄ 터미널 창을 μ—΄κ±°λ‚˜ ν™˜κ²½ λ³€μˆ˜λ₯Ό λ°˜μ˜ν•œ λ’€ μ•„λž˜ λͺ…λ Ήμ–΄λ₯Ό κ°€λ™ν•˜μ„Έμš”:" + info " codex auth # 인증 μ§„ν–‰" + info " codex # μ—μ΄μ „νŠΈ μ‹€ν–‰" + else + error "Codex CLI 곡식 μ„€μΉ˜ 슀크립트 가동 쀑 μ—λŸ¬κ°€ λ°œμƒν–ˆμŠ΅λ‹ˆλ‹€." + fi +} + +main "$@"