Customizing Raycast Extensions

Introduction⌗
Raycast is a system utility tool developed specifically for macOS that allows you to complete most common operations without using a mouse. If you’re used to using Spotlight to launch applications or search for files, Raycast will definitely become your new favorite tool!
Motivation⌗
I’ve been using Raycast for over two years now, and I find it extremely convenient. What makes Raycast particularly powerful is its robust extension ecosystem, with many productivity tools contributing their own extensions:
The extensions I use most frequently are:
- Docker Hub
- UUID Generator
- Composer Packagist
- Password Generator
- Go Package Search
These extensions are provided by excellent third-party developers, but some aspects of the user experience could still be improved. For example, with the Docker Hub extension, when I want to search for a Docker image, it automatically requests the default list page as soon as I enter the extension, even before I’ve typed anything. For me, I use this extension with a specific purpose - to search for the plugins I want - and I don’t want to wait for the default list to load every time before entering the Docker image name I’m looking for.
The Composer Packagist extension has the same issue, automatically requesting the default list page when opened.
Password Generator is the extension I use most often. What frustrates me most is having to uncheck the Use special characters?
option every time I generate a password, since many services don’t support special characters. Additionally, I have to manually close the Raycast popup after generating a password, which goes against Raycast’s philosophy.
Forking Extensions⌗
One day when I was bored, I browsed through Raycast’s developer documentation and discovered that plugin development is quite simple - you just need to know a bit of TypeScript. Following the official documentation, I forked the extensions to my local machine. By reading the source code of these extensions and the official developer documentation, I quickly customized these extensions to meet my expectations.
Final Results⌗
Docker Hub⌗
Composer Packagist⌗
Password Generator⌗
In addition to optimizing default options, I also added preference settings, including a Pop to root search behavior
option that allows users to customize what happens after generating a password:
Conclusion⌗
I’ve uploaded the modified code to my raycast-extensions repository on GitHub.
If you’re interested, you can clone it, install the dependencies, and run npm run build
in the extension directory. Finally, install the local extension in Raycast.
I hope this is helpful, Happy hacking…