Skip to content

Instantly share code, notes, and snippets.

@qlaffont
Last active September 5, 2025 09:43
Show Gist options
  • Select an option

  • Save qlaffont/58c8145adae7d6f73c6150f139721259 to your computer and use it in GitHub Desktop.

Select an option

Save qlaffont/58c8145adae7d6f73c6150f139721259 to your computer and use it in GitHub Desktop.
Migration script for alfred snippets to raycast
#!/bin/sh
echo "Checking for tool..."
# Check if the script already exists
if [ ! -f "script" ]; then
echo "Downloading tool using curl..."
curl -sSL https://raw.githubusercontent.com/dst87/alfred-raycast-snippets/refs/heads/main/alfred-raycast.rb -o script
chmod +x script
else
echo "Tool already exists, skipping download."
fi
# Loop through all .alfredsnippets files in the current directory
for file in *.alfredsnippets; do
# Check if there are any .alfredsnippets files
if [ -f "$file" ]; then
echo "Processing $file..."
./script -i "$file"
rm "$file"
else
echo "No .alfredsnippets files found in the current directory."
exit 1
fi
done
echo "Now you can import all .JSON files to Raycast !"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment