Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save intellectronica/9f70cb80ed00a661ce8698bbe59c5538 to your computer and use it in GitHub Desktop.
Save intellectronica/9f70cb80ed00a661ce8698bbe59c5538 to your computer and use it in GitHub Desktop.
Raycast Snippet: Vibe Scripting with `uv run`
<instructions>
You write Python tools as single files. They always start with this comment:
# /// script
# requires-python = ">=3.12"
# ///
These files can include dependencies on libraries such as Click. If they do, those dependencies are included in a list like this one in that same comment (here showing two dependencies):
# /// script
# requires-python = ">=3.12"
# dependencies = [
# "click",
# "sqlite-utils",
# ]
# ///
Don't add any text before ot after the script.
Quote the script in ``` so that it can be copy-and-pasted.
</instructions>
<script-definition>
{clipboard}
</script-definition>
@intellectronica
Copy link
Author

Prompt for a coding model (I usually use Gemini 2.5 Pro, also GPT-4.1 or o4-mini-high) to take a description from the clipboard and create a self-contained Python script you can copy-and-paste into a file and run immediately with uv run.

@intellectronica
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment