MAC 电脑快速打开claude code 终端

实现效果

我们直接在文件夹上右键,直接打开claude

实现路径

选择快捷操作

选择文件或文件夹 位于选择 访达

拖动运行applescript到中间的窗口

添加下面的脚本

这个脚本访是使用iterm打开,如果使用其他终端打开,可以询问豆包改代码

复制代码
on run {input, parameters}
	set targetPath to POSIX path of (item 1 of input)
	-- 用 iTerm2 打开目录并执行 claude 命令
	tell application "iTerm"
		create window with default profile
		tell current window
			tell current session
				write text "cd " & quoted form of targetPath
				write text "claude"
			end tell
		end tell
	end tell
	
	return input
end run

如果需要添加claude 无需确认权限的模式可是使用下面的脚本

复制代码
on run {input, parameters}
	set targetPath to POSIX path of (item 1 of input)
	-- 用 iTerm2 打开目录并执行 claude 命令
	tell application "iTerm"
		create window with default profile
		tell current window
			tell current session
				write text "cd " & quoted form of targetPath
				write text "claude --dangerously-skip-permissions"
			end tell
		end tell
	end tell
	
	return input
end run
相关推荐
Mintimate16 分钟前
WorkBuddy 上手: 让脚本项目 Homebrew CN 变成会排障的 Agent
macos·边缘计算·agent
fthux1 天前
如果你用 Mac,那你可能需要 Noti Shift
macos·开源·github
counterxing4 天前
最近发现一个 Mac 工具,有点像把 Raycast、语音输入法、截图和录屏塞到了一起
macos·ai编程·claude
元Y亨H11 天前
MacBook Air 开发神器:IDEA 与 PyCharm 极简安装及环境配置
macos
yuanyxh12 天前
macOS 应用 - 纯对话生成
前端·macos·ai编程
AI创界者14 天前
PilotTTS 一键整合包(Win/Mac):8G 显存畅跑,实测解锁情绪与副语言的精准控制
人工智能·macos·aigc·音视频
AirDroid_cn14 天前
系统终端与iTerm2字体看起来不一样?macOS Sequoia统一渲染指南
macos
JiaWen技术圈14 天前
2026 年的 macOS 磁盘清理方法
macos
lichong95114 天前
让AI自己用电脑!Cua:后台操作鼠标键盘,Mac/Windows/Linux全支持
人工智能·macos·ai·计算机外设·agent·提示词