本文参考了NPM中文文档写作而成的

npm whoami

显示 npm 用户名

npm whoami 使用

npm whoami [--registry <registry>]

npm whoami 说明

将 username 配置打印到标准输出。
本文参考NPM中文文档