FlareStart
HomeNewsHow ToSources
FlareStart

Where developers start their day. All the tech news & tutorials that matter, in one place.

Quick Links

  • Home
  • News
  • Tutorials
  • Sources
  • Privacy Policy

Connect

© 2026 FlareStart. All rights reserved.

Back to articles
Sync a Private Repo Subfolder to a Public Repo Using GitHub Actions 🔄🚀
How-ToWeb Development

Sync a Private Repo Subfolder to a Public Repo Using GitHub Actions 🔄🚀

via Dev.to Webdevvineel vanjari1mo ago

While building my website 🌐, I ran into an architecture constraint 🧠. My entire repository needed to stay private 🔒 because it contains drafts and internal structure. However, one folder (/website) powers the basic version of my blog and had to be public 🌍. I didn’t want: Duplicate repositories 📂 Manual copying ❌ Risk of exposing private files 🚫 Inconsistent content between repos 🔁 ⚙️ The Solution I implemented a GitHub Actions workflow 🤖 inside the private repository that: Triggers only on website/** changes 📁 Uses a Personal Access Token (PAT) stored as a secret 🔑 Clones the public repository 🌐 Syncs using rsync --delete 🪞 Commits and pushes automatically 🚀 The --delete flag ensures removed files are also mirrored, keeping both repositories perfectly in sync 🔄. 🏗️ Final Setup Private repo → Full development workspace 🧑‍💻 Public repo → Clean blog content layer 📦 Publishing → Fully automated pipeline ⚡ This approach keeps a single source of truth 📌 while maintaining proper separation o

Continue reading on Dev.to Webdev

Opens in a new tab

Read Full Article
21 views

Related Articles

How-To

What I learned about X-HEEP by Benchmarking

Medium Programming • 9h ago

No more Chinese Polestar 3s as production shifts entirely to the US
How-To

No more Chinese Polestar 3s as production shifts entirely to the US

Ars Technica • 10h ago

How-To

The most important 40 mcq with its answers How to use Android visual studio to make a mobile app

Medium Programming • 10h ago

What is Agent Script? How to Build Agents with It in Agentforce
How-To

What is Agent Script? How to Build Agents with It in Agentforce

Medium Programming • 10h ago

I Coded 3 Famous Trading Strategies in Pine Script and Backtested All of Them. None Passed.
How-To

I Coded 3 Famous Trading Strategies in Pine Script and Backtested All of Them. None Passed.

Medium Programming • 11h ago

Discover More Articles