Add local git documentation and commit script - GitHub sync disabled
This commit is contained in:
10
.gitignore
vendored
10
.gitignore
vendored
@@ -7,3 +7,13 @@ publish_old/
|
|||||||
*.db-shm
|
*.db-shm
|
||||||
*.db-wal
|
*.db-wal
|
||||||
wwwroot/uploads/
|
wwwroot/uploads/
|
||||||
|
|
||||||
|
# Prevent GitHub credentials
|
||||||
|
.git/config.github
|
||||||
|
github-credentials
|
||||||
|
.github-token
|
||||||
|
|
||||||
|
# Environment files (already ignored but adding for clarity)
|
||||||
|
backend/.env
|
||||||
|
.env
|
||||||
|
*.env.local
|
||||||
|
|||||||
59
GIT-README.md
Normal file
59
GIT-README.md
Normal file
@@ -0,0 +1,59 @@
|
|||||||
|
# Local Git Repository - No GitHub Sync
|
||||||
|
|
||||||
|
This repository is configured for **LOCAL VERSION CONTROL ONLY**.
|
||||||
|
|
||||||
|
## ✅ Current Configuration
|
||||||
|
|
||||||
|
- ✅ Git is enabled for version control
|
||||||
|
- ✅ All commits are stored locally on this server
|
||||||
|
- ✅ **NO** GitHub remote is configured
|
||||||
|
- ✅ **NO** changes will be pushed online
|
||||||
|
- ✅ All changes stay on this server only
|
||||||
|
|
||||||
|
## 📝 How to Commit Changes
|
||||||
|
|
||||||
|
### Easy Method (Recommended)
|
||||||
|
Use the provided script:
|
||||||
|
```bash
|
||||||
|
cd /media/pts/Website/SkyArtShop
|
||||||
|
./local-commit.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
### Manual Method
|
||||||
|
```bash
|
||||||
|
cd /media/pts/Website/SkyArtShop
|
||||||
|
git add -A
|
||||||
|
git commit -m "Your commit message here"
|
||||||
|
```
|
||||||
|
|
||||||
|
## 🔍 View Your Commits
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd /media/pts/Website/SkyArtShop
|
||||||
|
git log --oneline
|
||||||
|
```
|
||||||
|
|
||||||
|
## ✋ Important Notes
|
||||||
|
|
||||||
|
1. **No GitHub Sync**: This repository has NO GitHub remote configured
|
||||||
|
2. **Local Only**: All commits are stored in `/media/pts/Website/SkyArtShop/.git/`
|
||||||
|
3. **Server Backups**: Make sure to backup this entire folder to preserve your git history
|
||||||
|
4. **No Online Profile**: Your commits will NOT appear on your GitHub profile
|
||||||
|
|
||||||
|
## 🚫 What NOT to Do
|
||||||
|
|
||||||
|
- ❌ Do NOT run `git remote add origin <url>`
|
||||||
|
- ❌ Do NOT run `git push`
|
||||||
|
- ❌ Do NOT connect this to GitHub
|
||||||
|
|
||||||
|
## ✅ What You Can Do
|
||||||
|
|
||||||
|
- ✅ Commit changes locally anytime
|
||||||
|
- ✅ View commit history
|
||||||
|
- ✅ Create branches
|
||||||
|
- ✅ Revert to previous versions
|
||||||
|
- ✅ Track all your changes over time
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
Last Updated: December 13, 2025
|
||||||
45
local-commit.sh
Executable file
45
local-commit.sh
Executable file
@@ -0,0 +1,45 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# Local Git Commit Script
|
||||||
|
# This script commits all changes locally without pushing to GitHub
|
||||||
|
|
||||||
|
cd /media/pts/Website/SkyArtShop
|
||||||
|
|
||||||
|
echo "========================================="
|
||||||
|
echo " Local Git Commit (No GitHub Sync)"
|
||||||
|
echo "========================================="
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
# Show current changes
|
||||||
|
echo "Current changes:"
|
||||||
|
git status --short
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
# Ask for commit message
|
||||||
|
read -p "Enter commit message: " commit_msg
|
||||||
|
|
||||||
|
if [ -z "$commit_msg" ]; then
|
||||||
|
echo "Error: Commit message cannot be empty"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Stage all changes
|
||||||
|
echo "Staging all changes..."
|
||||||
|
git add -A
|
||||||
|
|
||||||
|
# Commit
|
||||||
|
echo "Committing changes..."
|
||||||
|
git commit -m "$commit_msg"
|
||||||
|
|
||||||
|
if [ $? -eq 0 ]; then
|
||||||
|
echo ""
|
||||||
|
echo "✅ Changes committed successfully!"
|
||||||
|
echo "📁 All changes are stored locally on this server"
|
||||||
|
echo "🚫 No changes will be pushed to GitHub"
|
||||||
|
echo ""
|
||||||
|
echo "Recent commits:"
|
||||||
|
git log --oneline -3
|
||||||
|
else
|
||||||
|
echo ""
|
||||||
|
echo "❌ Commit failed"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
Reference in New Issue
Block a user