diff --git a/book/cli/help.py b/book/cli/help.py index f606f72a9082..d63918c561fd 100755 --- a/book/cli/help.py +++ b/book/cli/help.py @@ -182,7 +182,7 @@ def help_markdown(cmd: list[str], s: str): ```bash $ {' '.join(cmd)} --help -{s.strip()} +{preprocess_help(s.strip())} ```""" @@ -250,6 +250,15 @@ def command_name(cmd: str): """Returns the name of a command.""" return cmd.split("/")[-1] +def preprocess_help(s: str): + """Preprocesses the help output of a command.""" + # Remove the user-specific paths. + s = re.sub(r"default: /.*/reth", "default: ", s) + # Remove the commit SHA. + s = re.sub(r"-[0-9A-Fa-f]{7}/", "-XXXXXXX/", s) + + return s + if __name__ == "__main__": main() diff --git a/book/cli/reth.md b/book/cli/reth.md index a141dd4bd71a..08772686347f 100644 --- a/book/cli/reth.md +++ b/book/cli/reth.md @@ -50,7 +50,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/config.md b/book/cli/reth/config.md index 5734cc185b96..bd1abe4fe9d6 100644 --- a/book/cli/reth/config.md +++ b/book/cli/reth/config.md @@ -40,7 +40,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db.md b/book/cli/reth/db.md index 011721681010..0ef1ac526d11 100644 --- a/book/cli/reth/db.md +++ b/book/cli/reth/db.md @@ -71,7 +71,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/clear.md b/book/cli/reth/db/clear.md index 028418d884f8..6015dc75173e 100644 --- a/book/cli/reth/db/clear.md +++ b/book/cli/reth/db/clear.md @@ -49,7 +49,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/diff.md b/book/cli/reth/db/diff.md index c51f4c17a36c..6c03b8a9b70b 100644 --- a/book/cli/reth/db/diff.md +++ b/book/cli/reth/db/diff.md @@ -68,7 +68,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/drop.md b/book/cli/reth/db/drop.md index c2f45b2b8bc3..ab87c4d746b1 100644 --- a/book/cli/reth/db/drop.md +++ b/book/cli/reth/db/drop.md @@ -48,7 +48,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/get.md b/book/cli/reth/db/get.md index 20a2cbd9590a..e35b60345c01 100644 --- a/book/cli/reth/db/get.md +++ b/book/cli/reth/db/get.md @@ -57,7 +57,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/list.md b/book/cli/reth/db/list.md index ff0b34523575..3f9ed77e0ac4 100644 --- a/book/cli/reth/db/list.md +++ b/book/cli/reth/db/list.md @@ -91,7 +91,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/path.md b/book/cli/reth/db/path.md index e5b39fba6b89..6180bab9203d 100644 --- a/book/cli/reth/db/path.md +++ b/book/cli/reth/db/path.md @@ -45,7 +45,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/snapshot.md b/book/cli/reth/db/snapshot.md index aaaaedfadd4f..2be9ce0f7adc 100644 --- a/book/cli/reth/db/snapshot.md +++ b/book/cli/reth/db/snapshot.md @@ -94,7 +94,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/stats.md b/book/cli/reth/db/stats.md index 7ca3dda5b157..385935827869 100644 --- a/book/cli/reth/db/stats.md +++ b/book/cli/reth/db/stats.md @@ -45,7 +45,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/db/version.md b/book/cli/reth/db/version.md index 184b80a8c767..847dc0cb897c 100644 --- a/book/cli/reth/db/version.md +++ b/book/cli/reth/db/version.md @@ -45,7 +45,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/debug.md b/book/cli/reth/debug.md index 1a1df0f002ea..f41966bebee6 100644 --- a/book/cli/reth/debug.md +++ b/book/cli/reth/debug.md @@ -41,7 +41,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/import.md b/book/cli/reth/import.md index 5ff665742f86..b92a0c9a18a3 100644 --- a/book/cli/reth/import.md +++ b/book/cli/reth/import.md @@ -68,7 +68,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/init.md b/book/cli/reth/init.md index 3bb6d111b211..3f5353176002 100644 --- a/book/cli/reth/init.md +++ b/book/cli/reth/init.md @@ -59,7 +59,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/node.md b/book/cli/reth/node.md index a73ef3b07dd8..ac9466f21b8b 100644 --- a/book/cli/reth/node.md +++ b/book/cli/reth/node.md @@ -93,7 +93,7 @@ Networking: --identity Custom node identity - [default: reth/v0.1.0-alpha.13-5062b7ea8/x86_64-unknown-linux-gnu] + [default: reth/v0.1.0-alpha.13-82f7f45e/aarch64-apple-darwin] --p2p-secret-key Secret key to use for this node. @@ -173,7 +173,7 @@ RPC: --ipcpath Filename for IPC socket/pipe within the datadir - [default: /tmp/reth.ipc] + [default: .ipc] --authrpc.addr Auth server address to listen on @@ -333,7 +333,7 @@ Builder: --builder.extradata Block extra data set by the payload builder - [default: reth/v0.1.0-alpha.13/linux] + [default: reth/v0.1.0-alpha.13/macos] --builder.gaslimit Target gas ceiling for built blocks @@ -425,7 +425,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/p2p.md b/book/cli/reth/p2p.md index ad4033d7bb61..835ac0a8d600 100644 --- a/book/cli/reth/p2p.md +++ b/book/cli/reth/p2p.md @@ -105,7 +105,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/p2p/body.md b/book/cli/reth/p2p/body.md index c2a6620fca7a..a5c3189affb7 100644 --- a/book/cli/reth/p2p/body.md +++ b/book/cli/reth/p2p/body.md @@ -29,7 +29,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/p2p/header.md b/book/cli/reth/p2p/header.md index 22cfcbfbc974..52d0630e6546 100644 --- a/book/cli/reth/p2p/header.md +++ b/book/cli/reth/p2p/header.md @@ -29,7 +29,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/recover.md b/book/cli/reth/recover.md index 18085030fef8..5f2b79d6dd2f 100644 --- a/book/cli/reth/recover.md +++ b/book/cli/reth/recover.md @@ -38,7 +38,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/recover/storage-tries.md b/book/cli/reth/recover/storage-tries.md index c4f3542d902b..f13cc9e31f18 100644 --- a/book/cli/reth/recover/storage-tries.md +++ b/book/cli/reth/recover/storage-tries.md @@ -45,7 +45,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage.md b/book/cli/reth/stage.md index e2f9322e248e..a0365e98f2f7 100644 --- a/book/cli/reth/stage.md +++ b/book/cli/reth/stage.md @@ -41,7 +41,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/drop.md b/book/cli/reth/stage/drop.md index 0e8abdc11571..97e437d87891 100644 --- a/book/cli/reth/stage/drop.md +++ b/book/cli/reth/stage/drop.md @@ -62,7 +62,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/dump.md b/book/cli/reth/stage/dump.md index 68cfafd8c250..c5f08bb2f5a3 100644 --- a/book/cli/reth/stage/dump.md +++ b/book/cli/reth/stage/dump.md @@ -66,7 +66,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/dump/account-hashing.md b/book/cli/reth/stage/dump/account-hashing.md index 73cd7b5afe4e..7524e4ac7360 100644 --- a/book/cli/reth/stage/dump/account-hashing.md +++ b/book/cli/reth/stage/dump/account-hashing.md @@ -37,7 +37,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/dump/execution.md b/book/cli/reth/stage/dump/execution.md index d5b8e67a8d90..2025012ad3f3 100644 --- a/book/cli/reth/stage/dump/execution.md +++ b/book/cli/reth/stage/dump/execution.md @@ -37,7 +37,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/dump/merkle.md b/book/cli/reth/stage/dump/merkle.md index 648719c01b09..e69b51cdde9b 100644 --- a/book/cli/reth/stage/dump/merkle.md +++ b/book/cli/reth/stage/dump/merkle.md @@ -37,7 +37,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/dump/storage-hashing.md b/book/cli/reth/stage/dump/storage-hashing.md index 57e84973bfe0..7ef46bb5f3ef 100644 --- a/book/cli/reth/stage/dump/storage-hashing.md +++ b/book/cli/reth/stage/dump/storage-hashing.md @@ -37,7 +37,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/run.md b/book/cli/reth/stage/run.md index 9464f8d6544a..112d537f5a38 100644 --- a/book/cli/reth/stage/run.md +++ b/book/cli/reth/stage/run.md @@ -109,7 +109,7 @@ Networking: --identity Custom node identity - [default: reth/v0.1.0-alpha.13-5062b7ea8/x86_64-unknown-linux-gnu] + [default: reth/v0.1.0-alpha.13-82f7f45e/aarch64-apple-darwin] --p2p-secret-key Secret key to use for this node. @@ -163,7 +163,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/unwind.md b/book/cli/reth/stage/unwind.md index 0928dd413724..6e276803b548 100644 --- a/book/cli/reth/stage/unwind.md +++ b/book/cli/reth/stage/unwind.md @@ -64,7 +64,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/unwind/num-blocks.md b/book/cli/reth/stage/unwind/num-blocks.md index 5127cdef58ba..0a9bc15c2adf 100644 --- a/book/cli/reth/stage/unwind/num-blocks.md +++ b/book/cli/reth/stage/unwind/num-blocks.md @@ -49,7 +49,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/stage/unwind/to-block.md b/book/cli/reth/stage/unwind/to-block.md index 4ab957d3c6f0..d3a5cc712af7 100644 --- a/book/cli/reth/stage/unwind/to-block.md +++ b/book/cli/reth/stage/unwind/to-block.md @@ -49,7 +49,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/test-vectors.md b/book/cli/reth/test-vectors.md index 739f28621ee8..b79b399dd7f3 100644 --- a/book/cli/reth/test-vectors.md +++ b/book/cli/reth/test-vectors.md @@ -38,7 +38,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file diff --git a/book/cli/reth/test-vectors/tables.md b/book/cli/reth/test-vectors/tables.md index e7d6cdb6adc9..f54af54b3acb 100644 --- a/book/cli/reth/test-vectors/tables.md +++ b/book/cli/reth/test-vectors/tables.md @@ -38,7 +38,7 @@ Logging: --log.file.directory The path to put log files in - [default: /home/doni/.config/cache/reth/logs] + [default: /logs] --log.file.max-size The maximum size (in MB) of one log file