Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display path to default datadir in help output #2881

Merged
merged 2 commits into from
Dec 28, 2023

Conversation

torkelrogstad
Copy link
Contributor

Using default_value_os_t, display the default data directory.

Output of --help pasted below, with this commit applied. Note /Users/torkel/Library/Application Support/ord is included.

❯ ./target/debug/ord --help
Usage: ord [OPTIONS] <COMMAND>

Commands:
  balances  List all rune balances
  decode    Decode a transaction
  epochs    List the first satoshis of each reward epoch
  find      Find a satoshi's current location
  index     Index commands
  list      List the satoshis in an output
  parse     Parse a satoshi from ordinal notation
  preview   Run an explorer server populated with inscriptions
  runes     List all runes
  server    Run the explorer server
  subsidy   Display information about a block's subsidy
  supply    Display Bitcoin supply information
  teleburn  Generate teleburn addresses
  traits    Display satoshi traits
  wallet    Wallet commands
  help      Print this message or the help of the given subcommand(s)

Options:
      --bitcoin-data-dir <BITCOIN_DATA_DIR>
          Load Bitcoin Core data dir from <BITCOIN_DATA_DIR>.
      --bitcoin-rpc-pass <BITCOIN_RPC_PASS>
          Authenticate to Bitcoin Core RPC with <RPC_PASS>.
      --bitcoin-rpc-user <BITCOIN_RPC_USER>
          Authenticate to Bitcoin Core RPC as <RPC_USER>.
      --chain <CHAIN_ARGUMENT>
          Use <CHAIN>. [default: mainnet] [possible values: mainnet, testnet, signet, regtest]
      --config <CONFIG>
          Load configuration from <CONFIG>.
      --config-dir <CONFIG_DIR>
          Load configuration from <CONFIG_DIR>.
      --cookie-file <COOKIE_FILE>
          Load Bitcoin Core RPC cookie file from <COOKIE_FILE>.
      --data-dir <DATA_DIR>
          Store index in <DATA_DIR>. [default: "/Users/torkel/Library/Application Support/ord"]
      --db-cache-size <DB_CACHE_SIZE>
          Set index cache to <DB_CACHE_SIZE> bytes. By default takes 1/4 of available RAM.
      --first-inscription-height <FIRST_INSCRIPTION_HEIGHT>
          Don't look for inscriptions below <FIRST_INSCRIPTION_HEIGHT>.
      --height-limit <HEIGHT_LIMIT>
          Limit index to <HEIGHT_LIMIT> blocks.
      --index <INDEX>
          Use index at <INDEX>.
      --index-runes
          Track location of runes. RUNES ARE IN AN UNFINISHED PRE-ALPHA STATE AND SUBJECT TO CHANGE AT ANY TIME.
      --index-sats
          Track location of all satoshis.
  -r, --regtest
          Use regtest. Equivalent to `--chain regtest`.
      --rpc-url <RPC_URL>
          Connect to Bitcoin Core RPC at <RPC_URL>.
  -s, --signet
          Use signet. Equivalent to `--chain signet`.
  -t, --testnet
          Use testnet. Equivalent to `--chain testnet`.
      --wallet <WALLET>
          Use wallet named <WALLET>. [default: ord]
  -h, --help
          Print help
  -V, --version
          Print version

Copy link
Collaborator

@raphjaph raphjaph left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great, thanks!

@raphjaph raphjaph merged commit eddfc7b into ordinals:master Dec 28, 2023
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants