![raycast-z](/dir/raycast-z/raw/main/icons/z.png)
Seamless zoxide integration for Raycast. Ergonomic script commands for navigating and managing your directories.
![Demo](https://private-user-images.githubusercontent.com/6627316/408993705-bc6a2b88-4a56-454c-bb21-1f37645642e2.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk1MjY5NzYsIm5iZiI6MTczOTUyNjY3NiwicGF0aCI6Ii82NjI3MzE2LzQwODk5MzcwNS1iYzZhMmI4OC00YTU2LTQ1NGMtYmIyMS0xZjM3NjQ1NjQyZTIuZ2lmP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxNCUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTRUMDk1MTE2WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9YmU1OWNmNWFlNTg5Nzg1Zjk2YTcxYjY4MmYyZDQ1YzI4NjdjYzIxYTNiYWFmNTk1MjczZDg3OGNjNjljMjA0NiZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.fAoMqfdD7Sge1cK2cQX3Ma9JVp5coAtF0tSf1VnE1Ss)
- Clone this repository
- Add the
commands
directory as a Script Directory in Raycast (installation guide) - If you're using an IDE other than VS Code, set your editor in
commands/edit.sh
, due to how Raycast runs scripts,$EDITOR
may not be available, so it is set manually. Defaults tocode
for VS Code. - Launch Raycast and try it out!
The raycast-z commands leverage your existing zoxide
database (automatically built as you navigate in your shell) to quickly access directories.
Simply enter a directory name or pattern, and z will find the best match.
You can also use absolute paths directly, even if they're not in your
zoxide
database.
- Create a new script command
{action}.sh
in thecommands
directory, usingopen.sh
as your template - Update the command call from
_z "$1" open .
to your desired action:_z "$1" {your_command}
The
_z
function (defined inlib/_z.sh
) handles the zoxide query and command execution in the target directory - Configure the
@raycast.*
metadata to your needsNeed a custom icon? Use our ray.so template
- Test your new command in Raycast