When doing local development, I have to export a token needed for downloading dependencies from a private repository. For example:
export NPM_TOKEN=token_value
I want to make sure that this token is not stored in the shell history (that's an easy part, I don't ask about that) and that it comes from a secure place, without a need to type it).
What are the best practices for keeping and retrieving such secrets on a local machine?