CLI Companion

  • Hugging Face CLI
    • login
    • whoami
    • repo create
    • upload
    • download
    • lfs-enable-largefiles
    • scan-cache
    • delete-cache
  • Hapi CLI
    • new
    • start
    • build
    • test
    • plugin create
    • route add
  • Cloudflared
    • tunnel
    • tunnel run
    • tunnel list
    • tunnel delete
    • access
    • access tcp
    • update

    The command `whoami` is a standard Unix/Linux command that prints the effective username of the current user. It is not a command or subcommand within the Hugging Face CLI (`huggingface-cli`).

    The Hugging Face CLI does not have a direct equivalent to `whoami` that prints your Hugging Face Hub username. Instead, your authentication status and user identity are managed through access tokens.

    To manage your Hugging Face Hub authentication:

    * **Log in:**

    bash
    huggingface-cli login

    This command will prompt you to enter your Hugging Face Hub token. Once authenticated, your token is stored locally.

    * **Check environment for token (indirectly confirm login):**

    bash
    huggingface-cli env

    This command displays information about your Hugging Face CLI environment, including whether an `HF_HOME` directory is set and if a token is present in the configuration.

    * **Log out:**

    bash
    huggingface-cli logout

    This command removes the locally stored Hugging Face Hub token, effectively logging you out.

    While there's no `whoami` for the Hugging Face account, successful execution of commands that require authentication (e.g., `huggingface-cli repo create`) indicates that you are logged in with a valid token associated with your Hugging Face Hub user.