So I ran into a problem when automating my projects with bash shell script and python...
I want to write a program that can help me to create new repositories using GitHub. However, I ran into this problem when executing my code.
Essentially, what I want to do is run 'create repo repo-name' and create a new github repository locally.
function create() {
    cd
    cd path/to/python/file
    python3 gh-create-command.py $*
    if [$1 == 'repo']
    then
        <creating repository>
    fi
}
But when I run this code I get the error, bash: [repo: command not found.
Can someone help me out here?
Please reply if I should post the complete code.
Thanks.
EDIT: FULL CODE
function create() {
    cd
    cd path/to/python/file
    python3 gh-create-command.py $*
    echo $1
    if [ '$1' == 'repo' ]
    then
        cd
        cd path/
        mkdir $2
        cd $2
        touch README.md
        git init
        cd ..
        cd path/to/python/file
        python3 gh-create-online-repo.py $*
        git remote add origin 'https://github.com/advaitvariyar/$2.git'
        git add .
        git commit -m "initial commit"
        git push -u origin master
        code .
    fi
}
output: repo
 
    