Pushing a Local Ethereum Smart Home Project to GitHub: Problems Faced and How I Solved Them
While working on my Ethereum-based smart home authentication project, I encountered several unexpected issues when trying to push my local files from my PC to a GitHub repository. Although the task seemed simple, a combination of Git configuration issues, merge states, and editor problems made the process confusing.
📌 Project Context
The project is a blockchain-based smart home authentication system built using Ethereum and Truffle. The goal was simply to save and back up the complete local project structure to GitHub.
⚠️ Problems Encountered
- Git entered a
MERGINGstate unexpectedly - The default Git editor (Vim) opened and appeared “stuck”
- Terminal kept flickering with no visible changes
git commitreported “nothing to commit”- Confusion about whether files were actually pushed or not
🔍 Investigation and Diagnosis
Running the following commands helped clarify the situation:
git status git diff git status --ignored
These showed that:
- The working tree was clean
- Ignored directories like
node_modulesandbuildwere correctly excluded - The repository already had tracked files ready to push
🛠️ Key Fixes Applied
- Exited Vim correctly using
:wqor:q! - Configured Git to use Notepad instead of Vim:
git config --global core.editor notepad
- Verified the remote repository:
git remote -v
- Confirmed branch state and proceeded with push
🚀 Final Push Command
git push origin main
After executing this command, Git successfully compressed, wrote, and uploaded all project objects to the remote GitHub repository.
✅ Proof of Successful Git Push
The screenshot below confirms that the project was successfully pushed to the GitHub repository.
The terminal output shows objects being written and the main branch updated without errors.
Figure: Terminal output confirming a successful git push origin main.
📂 GitHub Repository
https://github.com/idris0001/blockchain-smart-home-auth
📘 Lessons Learned
- A clean working tree does not mean files are not already committed
- Git editors can cause confusion if not configured properly
- Always verify push results using terminal output and GitHub UI
This experience reinforced the importance of understanding Git states and configuration, especially when working on research or blockchain-based development projects.
Comments
Post a Comment