-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpush_to_github.sh
More file actions
61 lines (53 loc) · 1.88 KB
/
Copy pathpush_to_github.sh
File metadata and controls
61 lines (53 loc) · 1.88 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#!/bin/bash
# Quick script to push to GitHub
# Run this after creating the repository on GitHub
echo "========================================="
echo "Pushing NLP Translation Project to GitHub"
echo "========================================="
echo ""
# Check if repository exists on GitHub first
echo "⚠️ IMPORTANT: Before running this script:"
echo "1. Go to https://github.com/new"
echo "2. Create a repository named: SLAI_LLM_Final_Proj"
echo "3. DO NOT initialize with README or .gitignore"
echo "4. Then run this script"
echo ""
read -p "Have you created the repository on GitHub? (y/n) " -n 1 -r
echo ""
if [[ ! $REPLY =~ ^[Yy]$ ]]; then
echo "Please create the repository first, then run this script again."
exit 1
fi
# Add remote
echo "Adding remote repository..."
git remote add origin https://github.com/ShiboSusu/SLAI_LLM_Final_Proj 2>/dev/null || git remote set-url origin https://github.com/ShiboSusu/SLAI_LLM_Final_Proj
# Rename branch to main
echo "Renaming branch to main..."
git branch -M main
# Push to GitHub
echo "Pushing to GitHub..."
echo ""
echo "⚠️ You may be prompted for GitHub credentials:"
echo " Username: ShiboSusu"
echo " Password: Use a Personal Access Token (not your GitHub password)"
echo " Get token from: https://github.com/settings/tokens"
echo ""
git push -u origin main
if [ $? -eq 0 ]; then
echo ""
echo "========================================="
echo "✅ Successfully pushed to GitHub!"
echo "========================================="
echo ""
echo "View your repository at:"
echo "https://github.com/ShiboSusu/SLAI_LLM_Final_Proj"
echo ""
else
echo ""
echo "❌ Push failed. Please check:"
echo "1. Repository exists on GitHub"
echo "2. You have correct permissions"
echo "3. Your authentication credentials are correct"
echo ""
echo "See GITHUB_SETUP.md for detailed instructions"
fi