Pushing to GitHub without a password
Configure SSH on the local computer, generate a new SSH key if needed, and add the public key to the GitHub account.
The “trick” for using the key to push to a repo is that the repo’s remote on the local computer needs to be set to the SSH URL, not the HTTPS URL. Assuming the URL is currently set to an HTTPS URL, for example:
❯ git remote -v
origin https://github.com/scossar/zalgorithm_theme (fetch)
origin https://github.com/scossar/zalgorithm_theme (push)
updated it with:
❯ git remote set-url origin git@github.com:scossar/zalgorithm_theme.git
The pattern for the SSH URL is:
git@github.com:OWNER/REPOSITORY.git