Skip to content

Commit c0abc3e

Browse files
authored
Add quickstart script for macos (ordinals#1096)
1 parent 49cdd33 commit c0abc3e

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

quickstart/macos

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
#!/usr/bin/env bash
2+
3+
set -euxo pipefail
4+
5+
# install homebrew
6+
if ! command -v brew; then
7+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
8+
fi
9+
10+
# check homebrew
11+
brew --version
12+
13+
# install bitcoin
14+
if ! command -v bitcoind; then
15+
brew install bitcoin
16+
fi
17+
18+
# check bitcoind
19+
bitcoind --version
20+
21+
# write config
22+
if [[ ! -f ~/Library/Application\ Support/Bitcoin/bitcoin.conf ]]; then
23+
printf 'txindex=1\nsignet=1\n' > ~/Library/Application\ Support/Bitcoin/bitcoin.conf
24+
fi
25+
26+
# start bitcoind
27+
if ! bitcoin-cli getblockchaininfo; then
28+
brew services start bitcoin
29+
fi
30+
31+
# check bitcoind
32+
bitcoin-cli getblockchaininfo | grep signet
33+
34+
# install ord
35+
if ! command -v ord; then
36+
curl --proto '=https' --tlsv1.2 -fsLS https://ordinals.com/install.sh | bash -s
37+
fi
38+
39+
# check ord
40+
ord --version

0 commit comments

Comments
 (0)