Skip to content

Commit e9b80c6

Browse files
authored
feat: script
1 parent 1e1ec47 commit e9b80c6

4 files changed

Lines changed: 69 additions & 20 deletions

File tree

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,31 +35,31 @@ Install `bitcoinui` in your AI coding tool.
3535
### [Claude](https://code.claude.com/docs/en/slash-commands)
3636

3737
```sh
38-
curl -L -o ~/.claude/commands/bitcoinui.md https://bitcoinui.ai/bitcoinui.md
38+
curl -fsSL https://bitcoinui.ai/install.sh | bash
3939
claude
4040
/bitcoinui
4141
```
4242

4343
### [Codex](https://github.com/openai/codex/blob/main/docs/skills.md)
4444

4545
```sh
46-
curl -fsSL https://bitcoinui.ai/install-codex.sh | bash
46+
curl -fsSL https://bitcoinui.ai/install.sh | bash
4747
codex
4848
$bitcoinui
4949
```
5050

5151
### [Cursor](https://cursor.com/docs/agent/chat/commands)
5252

5353
```sh
54-
curl -L -o ~/.cursor/commands/bitcoinui.md https://bitcoinui.ai/bitcoinui.md
54+
curl -fsSL https://bitcoinui.ai/install.sh | bash
5555
cursor
5656
/bitcoinui
5757
```
5858

5959
### [OpenCode](https://opencode.ai/docs/commands/)
6060

6161
```sh
62-
curl -L -o ~/.config/opencode/command/bitcoinui.md https://bitcoinui.ai/bitcoinui.md
62+
curl -fsSL https://bitcoinui.ai/install.sh | bash
6363
opencode
6464
/bitcoinui
6565
```

site/index.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,28 +34,28 @@ <h1>Bitcoin UI iOS</h1>
3434
<h2 class="section-title">Design Review</h2>
3535
<section class="block" id="claude">
3636
<h2><a href="https://code.claude.com/docs/en/slash-commands">Claude</a></h2>
37-
<pre><code><span class="prompt">$</span> curl -L -o ~/.claude/commands/bitcoinui.md https://bitcoinui.ai/bitcoinui.md
37+
<pre><code><span class="prompt">$</span> curl -fsSL https://bitcoinui.ai/install.sh | bash
3838
<span class="prompt">$</span> claude
3939
<span class="prompt">&gt;</span> /bitcoinui</code></pre>
4040
</section>
4141

4242
<section class="block" id="codex">
4343
<h2><a href="https://github.com/openai/codex/blob/main/docs/skills.md">Codex</a></h2>
44-
<pre><code><span class="prompt">$</span> curl -fsSL https://bitcoinui.ai/install-codex.sh | bash
44+
<pre><code><span class="prompt">$</span> curl -fsSL https://bitcoinui.ai/install.sh | bash
4545
<span class="prompt">$</span> codex
4646
<span class="prompt">&gt;</span> $bitcoinui</code></pre>
4747
</section>
4848

4949
<section class="block" id="cursor">
5050
<h2><a href="https://cursor.com/docs/agent/chat/commands">Cursor</a></h2>
51-
<pre><code><span class="prompt">$</span> curl -L -o ~/.cursor/commands/bitcoinui.md https://bitcoinui.ai/bitcoinui.md
51+
<pre><code><span class="prompt">$</span> curl -fsSL https://bitcoinui.ai/install.sh | bash
5252
<span class="prompt">$</span> cursor
5353
<span class="prompt">&gt;</span> /bitcoinui</code></pre>
5454
</section>
5555

5656
<section class="block" id="opencode">
5757
<h2><a href="https://opencode.ai/docs/commands/">OpenCode</a></h2>
58-
<pre><code><span class="prompt">$</span> curl -L -o ~/.config/opencode/command/bitcoinui.md https://bitcoinui.ai/bitcoinui.md
58+
<pre><code><span class="prompt">$</span> curl -fsSL https://bitcoinui.ai/install.sh | bash
5959
<span class="prompt">$</span> opencode
6060
<span class="prompt">&gt;</span> /bitcoinui</code></pre>
6161
</section>

site/install-codex.sh

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,4 @@
11
#!/usr/bin/env bash
22
set -euo pipefail
33

4-
CODEX_HOME="${CODEX_HOME:-$HOME/.codex}"
5-
SKILL_DIR="$CODEX_HOME/skills/bitcoinui"
6-
REF_DIR="$SKILL_DIR/references"
7-
BASE_URL="https://bitcoinui.ai/skills/bitcoinui"
8-
9-
mkdir -p "$REF_DIR"
10-
11-
curl -fsSL -o "$SKILL_DIR/SKILL.md" "$BASE_URL/SKILL.md"
12-
curl -fsSL -o "$REF_DIR/bitcoinui-rubric.md" "$BASE_URL/references/bitcoinui-rubric.md"
13-
14-
echo "Installed to $SKILL_DIR"
15-
echo "Restart Codex to pick up new skills."
4+
curl -fsSL https://bitcoinui.ai/install.sh | bash

site/install.sh

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
#!/usr/bin/env bash
2+
set -euo pipefail
3+
4+
BITCOINUI_URL="https://bitcoinui.ai/bitcoinui.md"
5+
SKILL_BASE_URL="https://bitcoinui.ai/skills/bitcoinui"
6+
CODEX_HOME="${CODEX_HOME:-$HOME/.codex}"
7+
INSTALLED=0
8+
9+
echo "Installing bitcoinui..."
10+
echo ""
11+
12+
# Claude Code
13+
if command -v claude >/dev/null 2>&1 || [ -d "$HOME/.claude" ]; then
14+
mkdir -p "$HOME/.claude/commands"
15+
curl -fsSL -o "$HOME/.claude/commands/bitcoinui.md" "$BITCOINUI_URL"
16+
echo "Installed for Claude Code"
17+
INSTALLED=$((INSTALLED + 1))
18+
fi
19+
20+
# Cursor
21+
if command -v cursor >/dev/null 2>&1 || [ -d "$HOME/.cursor" ]; then
22+
mkdir -p "$HOME/.cursor/commands"
23+
curl -fsSL -o "$HOME/.cursor/commands/bitcoinui.md" "$BITCOINUI_URL"
24+
echo "Installed for Cursor"
25+
INSTALLED=$((INSTALLED + 1))
26+
fi
27+
28+
# OpenCode
29+
if command -v opencode >/dev/null 2>&1 || [ -d "$HOME/.config/opencode" ]; then
30+
mkdir -p "$HOME/.config/opencode/command"
31+
curl -fsSL -o "$HOME/.config/opencode/command/bitcoinui.md" "$BITCOINUI_URL"
32+
echo "Installed for OpenCode"
33+
INSTALLED=$((INSTALLED + 1))
34+
fi
35+
36+
# Codex
37+
if command -v codex >/dev/null 2>&1 || [ -d "$CODEX_HOME" ]; then
38+
SKILL_DIR="$CODEX_HOME/skills/bitcoinui"
39+
REF_DIR="$SKILL_DIR/references"
40+
mkdir -p "$REF_DIR"
41+
curl -fsSL -o "$SKILL_DIR/SKILL.md" "$SKILL_BASE_URL/SKILL.md"
42+
curl -fsSL -o "$REF_DIR/bitcoinui-rubric.md" "$SKILL_BASE_URL/references/bitcoinui-rubric.md"
43+
echo "Installed for Codex"
44+
INSTALLED=$((INSTALLED + 1))
45+
fi
46+
47+
echo ""
48+
49+
if [ "$INSTALLED" -eq 0 ]; then
50+
echo "No supported tools detected."
51+
echo ""
52+
echo "Install one of these first:"
53+
echo " - Claude Code: https://claude.ai/code"
54+
echo " - Cursor: https://cursor.com"
55+
echo " - OpenCode: https://opencode.ai"
56+
echo " - Codex: https://github.com/openai/codex"
57+
exit 1
58+
fi
59+
60+
echo "Done! Run /bitcoinui (or \$bitcoinui in Codex)."

0 commit comments

Comments
 (0)