File tree Expand file tree Collapse file tree 2 files changed +26
-0
lines changed
Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
2+
3+ # Required parameters:
4+ # @raycast.schemaVersion 1
5+ # @raycast.title Query cheat.sh
6+ # @raycast.mode fullOutput
7+ # @raycast.packageName Developer Utilities
8+
9+ # Optional parameters:
10+ # @raycast.icon images/cheat.png
11+ # @raycast.argument1 { "type": "text", "placeholder": "Language / Command" }
12+ # @raycast.argument2 { "type": "text", "placeholder": "Question", "optional": true }
13+
14+ # Documentation:
15+ # @raycast.author Jakub Lanski
16+ # @raycast.authorURL https://github.com/jaklan
17+ # @raycast.description Query the cheat.sh service (https://github.com/chubin/cheat.sh).
18+
19+ language=$1
20+ question=${2// / +}
21+
22+ if [ -z " $question " ]; then
23+ curl -s cht.sh/$language
24+ else
25+ curl -s cht.sh/$language /$question
26+ fi
You can’t perform that action at this time.
0 commit comments