-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit_git.sh
More file actions
executable file
·36 lines (30 loc) · 949 Bytes
/
Copy pathinit_git.sh
File metadata and controls
executable file
·36 lines (30 loc) · 949 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/bin/bash
# Initialize Git repository and make first commit
# Set Git repository name and username
echo "Enter your GitHub username:"
read GITHUB_USERNAME
echo "Enter repository name (default: shelf-print):"
read REPO_NAME
REPO_NAME=${REPO_NAME:-shelf-print}
# Initialize Git
git init
# Add all files
git add .
# Make first commit
git commit -m "Initial commit of Shelf Label Generator"
# Instructions for pushing to GitHub
echo ""
echo "Repository initialized locally. To push to GitHub:"
echo ""
echo "1. Create a repository on GitHub named: $REPO_NAME"
echo "2. Then run these commands:"
echo ""
echo " git remote add origin https://github.com/$GITHUB_USERNAME/$REPO_NAME.git"
echo " git branch -M main"
echo " git push -u origin main"
echo ""
echo "Alternatively, if you use SSH:"
echo ""
echo " git remote add origin git@github.com:$GITHUB_USERNAME/$REPO_NAME.git"
echo " git branch -M main"
echo " git push -u origin main"