Skip to content

Username conflict issue affecting git remote add #22

@HughG-50

Description

@HughG-50

I found the issue on my Mac machine, with retrieving the username from the .env file. The issue arose because my Github and Mac machine usernames were different.

On the following line in create.py
username = os.getenv("USERNAME")

My Mac machine username was somehow being retrieved instead of the Github username I had set in the .env file. This was causing the command git remote add origin <git@github.com:$USERNAME/$1.git> to insert the wrong username, causing it to fail.

Renaming the USERNAME to GITHUBUSERNAME in the codebase alleviated the issue.

That is, and in the .env files, the following was changed:

In create.py
username = os.getenv("GITHUBUSERNAME")

In .my_commands.sh
git remote add origin https://github.com/$GITHUBUSERNAME/$1.git

And .env file
GITHUBUSERNAME="<my_username>"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions