Skip to content

Instantly share code, notes, and snippets.

@Edmartt
Created July 12, 2023 20:53
Show Gist options
  • Save Edmartt/3a56ea5966508131d84332baef23260d to your computer and use it in GitHub Desktop.
Save Edmartt/3a56ea5966508131d84332baef23260d to your computer and use it in GitHub Desktop.
script for getting my go projects started with a basic structure
read -p 'Type the main directory project: ' dir_name
mkdir $dir_name && cd $dir_name
echo Starting the base structure for the project...
sleep 1
read -p 'type the project name: ' project_name
read -p 'type your github username: ' github_username
echo STARTING PROJECT...
echo creating base packages go projects...
sleep 2
mkdir internal && mkdir pkg
exec go mod init "github.com/$github_username/$project_name"
echo project created!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment