Skip to content

Make stellar keys public-key available.#1851

Closed
fnando wants to merge 2 commits into
mainfrom
keys-public-key
Closed

Make stellar keys public-key available.#1851
fnando wants to merge 2 commits into
mainfrom
keys-public-key

Conversation

@fnando

@fnando fnando commented Jan 27, 2025

Copy link
Copy Markdown
Member

What

Make stellar keys public-key available. Also update doc to state that address is an alias.

$ stellar keys -h
Create and manage identities including keys and addresses

Usage: stellar keys [OPTIONS] <COMMAND>

Commands:
  add         Add a new identity (keypair, ledger, OS specific secure store)
  public-key  Given an identity return its address (public key). Alias: `stellar keys address`
  fund        Fund an identity on a test network
  generate    Generate a new identity using a 24-word seed phrase
  ls          List identities
  rm          Remove an identity
  secret      Output an identity's secret key
  use         Set the default identity that will be used on all commands. This allows you to skip `--source-account` or setting a environment variable, while reusing this value in all commands that require it

Options:
  -h, --help  Print help

Options (Global):
      --global                     Use global config
      --config-dir <CONFIG_DIR>    Location of config directory, default is "."
  -f, --filter-logs <FILTER_LOGS>  Filter logs output. To turn on `stellar_cli::log::footprint=debug` or off `=off`. Can also use env var `RUST_LOG`
  -q, --quiet                      Do not write logs to stderr including `INFO`
  -v, --verbose                    Log DEBUG events
      --very-verbose               Log DEBUG and TRACE events [aliases: vv]
      --no-cache                   Do not cache your simulations and transactions [env: STELLAR_NO_CACHE=]

$ stellar keys address me
GBLIKM4JRVIENS3XVFXPO5AXQ6B76UUYKGFXHAXLNGRX4FS5U5HOC5MK

$ stellar keys public-key me
GBLIKM4JRVIENS3XVFXPO5AXQ6B76UUYKGFXHAXLNGRX4FS5U5HOC5MK

Why

Close #1768

Known limitations

N/A

@fnando fnando changed the title Make stellar address public-key available. Make stellar keys public-key available. Jan 27, 2025
@fnando fnando self-assigned this Jan 27, 2025
@willemneal

Copy link
Copy Markdown
Contributor

Isn't public-key already available? Is this because the alias wasn't showing up the markdown?

Here is the PR to fix that: #1771

I is best to let clap handle visible aliases since we have them in other places too.

@fnando

fnando commented Jan 28, 2025

Copy link
Copy Markdown
Member Author

Ah, nice! I still think keys public-key should be the canonical command, and address the alias (it's even how we named files).

@fnando fnando closed this Jan 28, 2025
@fnando fnando deleted the keys-public-key branch January 28, 2025 00:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Make contract install an alias of contract upload and keys address an alias of keys public-key

2 participants