Skip to content

Latest commit

Β 

History

9 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🧠 Zed Default Editor Setup Script

This is a simple script to make Zedβ€”or its Preview/Nightly buildsβ€”your default editor for all text/code files on macOS.

It:

  • Installs duti if needed
  • Asks if you want to use Zed, Zed Preview, or Zed Nightly
  • Associates a broad set of file types (including .mdx, .ts, .py, .json, .kt, .cs, .sql, etc.) with Zed
  • Automatically sets them via duti in one shot

πŸš€ Quickstart

πŸ§ͺ Option 1: One-liner Installer

No need to download anything β€” just run this in your terminal:

bash <(curl -fsSL https://raw.githubusercontent.com/JohnnyHoff/zed-default-editor/refs/heads/main/set_zed_defaults.sh)

🧰 Option 2: Manual Clone + Run

git clone https://github.com/YOUR-USERNAME/zed-default-editor.git
cd zed-default-editor
chmod +x set_zed_defaults.sh
./set_zed_defaults.sh

πŸ“¦ Requirements

  • macOS
  • Homebrew installed (used to install duti)

🧠 What’s Covered?

This script sets Zed as the default app for:

  • Plain text files (.txt, .md, .log, .ini)
  • Code files (.js, .ts, .py, .rs, .kt, .cs, .sql, .html, .css, etc.)
  • Configs (.json, .xml, .yml, .plist)
  • Markdown & MDX files (.md, .mdx)
  • Scripts (.sh, .bash, .php, .rb, etc.)

πŸ›‘ Troubleshooting

If Zed isn’t detected:

  • Make sure it's installed in /Applications
  • You can re-run the script any time

If Markdown files still open in Zed Preview:

  • Re-run the script and choose Zed
  • Restart Finder or log out/in to refresh Launch Services

πŸ§‘β€πŸ’» Contributing

Feel free to PR more file types, support for other editors, or general improvements!


πŸ“ License

MIT

About

set Zed as the default editor for file types

Resources

Stars

6 stars

Watchers

2 watching

Forks

Releases

Packages

Contributors

Languages