Show HN: 일반 영어로 쉘 명령을 실행하는 가장 쉬운 방법(앱 필요 없음)

hackernews | | 💼 비즈니스
#ai 모델 #claude #cli #shell #개발도구 #자동화
원문 출처: hackernews · Genesis Park에서 요약 및 분석

요약

쉘 명령어 문법을 잊어버릴 때 별도의 앱 없이 자연어로 명령을 실행할 수 있는 방법이 소개되었습니다. zsh/macOS 환경에서 .zshrc 파일에 한 줄의 프롬프트와 별칭 명령어만 추가하면, ‘@ run ffmpeg...’ 같은 문장을 입력했을 때 실제 실행 가능한 코드로 변환됩니다. 이 방식을 사용하면 명령어 기록에 자연어가 함께 저장되어 나중에 같은 작업을 쉽게 다시 실행할 수 있다는 장점이 있습니다.

본문

Type @ in your terminal and get a ready-to-run shell command back, powered by Claude Code. The command is placed into your zsh input buffer so you can review it before pressing Enter. cat > ~/.at_prompt $request" | head -1) printf "\r\033[K" # clear the thinking line print -z "$cmd" } Then reload your shell: source ~/.zshrc Or simply ask Claude Code to read this README and set it up for you: Read https://raw.githubusercontent.com/iafan/at-command/main/README.md and implement the setup @ list all jpg files larger than 5mb @ show my ipv4 address @ find and kill the process on port 3000 @ compress this directory into a tar.gz The generated command appears in your prompt buffer — press Enter to run it, or edit it first. Always review the generated command before running it. Any LLM can make mistakes — never execute a command you don't fully understand, especially ones that modify or delete files. @() is a zsh function that takes your natural language request as arguments.- It reads the system prompt from ~/.at_prompt and sends it along with your request to Claude Code in print mode (-p ). - Claude returns a single shell command. print -z pushes the command into the zsh line editor buffer so you can inspect/edit before executing.

Genesis Park 편집팀이 AI를 활용하여 작성한 분석입니다. 원문은 출처 링크를 통해 확인할 수 있습니다.

공유

관련 저널 읽기

전체 보기 →