{"id":31626367,"url":"https://github.com/dkmaker/satisfactory-sync-onedrive","last_synced_at":"2025-10-06T19:51:36.229Z","repository":{"id":316371577,"uuid":"1063083686","full_name":"dkmaker/Satisfactory-Sync-OneDrive","owner":"dkmaker","description":"🎮 Automatically sync your Satisfactory blueprints across all devices using OneDrive. Features bidirectional sync, version history, conflict resolution, and multi-device support. Runs every 10 minutes in the background with no window popups.","archived":false,"fork":false,"pushed_at":"2025-09-24T06:43:24.000Z","size":13,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-24T08:36:46.698Z","etag":null,"topics":["automation","backup","blueprints","coffee-stain-studios","game-tools","onedrive","powershell","satisfactory","satisfactory-game","scheduled-task","sync","windows"],"latest_commit_sha":null,"homepage":"https://www.satisfactorygame.com","language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dkmaker.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-24T06:29:31.000Z","updated_at":"2025-09-24T06:38:10.000Z","dependencies_parsed_at":"2025-09-24T08:36:49.725Z","dependency_job_id":"891d440e-1fc3-4764-a160-129ef69eb2d4","html_url":"https://github.com/dkmaker/Satisfactory-Sync-OneDrive","commit_stats":null,"previous_names":["dkmaker/satisfactory-sync-onedrive"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/dkmaker/Satisfactory-Sync-OneDrive","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dkmaker%2FSatisfactory-Sync-OneDrive","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dkmaker%2FSatisfactory-Sync-OneDrive/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dkmaker%2FSatisfactory-Sync-OneDrive/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dkmaker%2FSatisfactory-Sync-OneDrive/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dkmaker","download_url":"https://codeload.github.com/dkmaker/Satisfactory-Sync-OneDrive/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dkmaker%2FSatisfactory-Sync-OneDrive/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278671749,"owners_count":26025743,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-06T02:00:05.630Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","backup","blueprints","coffee-stain-studios","game-tools","onedrive","powershell","satisfactory","satisfactory-game","scheduled-task","sync","windows"],"created_at":"2025-10-06T19:51:31.441Z","updated_at":"2025-10-06T19:51:36.224Z","avatar_url":"https://github.com/dkmaker.png","language":"PowerShell","readme":"# Satisfactory Blueprint Sync for OneDrive\n\n[![PowerShell](https://img.shields.io/badge/PowerShell-5.1%2B-blue.svg)](https://learn.microsoft.com/en-us/powershell/)\n[![Windows](https://img.shields.io/badge/Platform-Windows%2010%2F11-blue.svg)](https://www.microsoft.com/windows)\n[![Satisfactory](https://img.shields.io/badge/Satisfactory-1.1-orange.svg)](https://www.satisfactorygame.com/)\n[![License](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE)\n\nAutomated bidirectional synchronization of Satisfactory blueprints with OneDrive, featuring version history, conflict resolution, and multi-device support.\n\n🎮 **Game:** [Satisfactory](https://www.satisfactorygame.com/) by [Coffee Stain Studios](https://www.coffeestainstudios.com/games/satisfactory)\n\n## Problem Solved\n\nSatisfactory blueprints are **not** synchronized to Steam Cloud. This solution:\n- **Bidirectional sync** between local Satisfactory folder and OneDrive\n- **Version history** with up to 10 versions per file stored in backups\n- **Conflict resolution** by keeping the newest file based on timestamps\n- **Multi-device support** with file-centric tracking and global file state\n- **Enhanced deletion handling** with immediate OneDrive cleanup and cross-device propagation\n- **Smart backup** for all conflicts, overwrites, and deletions with comprehensive coverage\n- **Companion file coordination** - .sbp and .sbpcfg files handled together\n- **Automatic OneDrive pinning** to ensure files are always available offline\n\n## Features\n\n- **Bidirectional Sync Modes**:\n  - `Bidirectional` (default): Syncs in both directions\n  - `LocalToCloud`: Only pushes local changes to OneDrive\n  - `CloudToLocal`: Only pulls OneDrive changes to local\n\n- **Version History**: Tracks up to 10 versions of each file with:\n  - Hash, timestamp, size, and device information\n  - Backup location for recovery\n  - Action type (overwrite, deletion, conflict)\n\n- **Intelligent Conflict Resolution**:\n  - Compares file timestamps when both changed\n  - Backs up the losing version before overwrite\n  - Preserves all file timestamps during copy operations\n  - Clear conflict logging with backup tracking\n\n- **OneDrive Integration**:\n  - Automatically pins folder for offline availability\n  - Checks pin status before setting to minimize overhead\n  - Optional flag to skip pinning if needed\n\n- **Comprehensive Logging**: Detailed sync operations log for troubleshooting\n\n## 🚀 Quick Start\n\n### Prerequisites\n\n- Windows 10/11\n- Windows PowerShell 5.1 (built into Windows 10/11)\n- OneDrive configured and running\n- Administrator privileges (for scheduled task installation)\n- [Satisfactory](https://store.steampowered.com/app/526870/Satisfactory/) installed\n\n### Installation\n\n1. **Clone or download this repository**\n   ```powershell\n   git clone https://github.com/dkmaker/Satisfactory-Sync-OneDrive.git\n   cd Satisfactory-Sync-OneDrive\n   ```\n\n2. **Run the installer as Administrator**\n   ```powershell\n   # Open Windows PowerShell as Administrator\n   # Set execution policy for current process (if needed)\n   Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope Process\n\n   # Run the installer\n   .\\Install-SyncScheduledTask.ps1\n   ```\n\n3. **That's it!** The sync will run automatically:\n   - At user logon\n   - Every 10 minutes throughout the day\n   - Logs available at `%OneDrive%\\Documents\\Satisfactory\\logs`\n\n## File Structure\n\n```\nOneDrive\\Documents\\Satisfactory\\\n├── metadata.json                   # Sync state and device tracking\n├── blueprints\\                     # Synced blueprints\n│   └── [Save Game Name]\\           # Folder per save game\n│       ├── Blueprint1.sbp          # Blueprint data\n│       └── Blueprint1.sbpcfg       # Blueprint config\n├── blueprints_backup\\               # Deleted file backups\n│   └── [yyyyMMddHHmmss]\\           # Timestamp folders\n│       └── [Save Game Name]\\       # Original structure preserved\n└── logs\\                           # Sync logs\n    └── sync_[yyyyMMdd].log        # Daily log files\n```\n\n## How It Works\n\n1. **Source Locations**:\n   - Local: `%LocalAppData%\\FactoryGame\\Saved\\SaveGames\\blueprints\\`\n   - Cloud: `%OneDrive%\\Documents\\Satisfactory\\blueprints\\`\n\n2. **Bidirectional Sync Process**:\n   - Scans both local and OneDrive folders\n   - Compares files using SHA256 hashes\n   - For conflicts (both changed): keeps newest based on LastWriteTime\n   - Backs up older versions before overwriting\n   - Preserves original file timestamps during all copy operations\n\n3. **Version History**:\n   - Maintains up to 10 versions per file (configurable)\n   - Each version includes hash, timestamp, device, and backup location\n   - Older versions automatically pruned (FIFO)\n\n4. **Enhanced Deletion Handling**:\n   - Detects deletions by comparing device's previous file list vs current scan\n   - Immediately removes deleted files from OneDrive with backup\n   - Handles companion files (.sbp/.sbpcfg) together during deletion\n   - Cross-device deletion propagation ensures consistency\n   - Supports file re-creation with same name (fresh lifecycle)\n   - All backups stored in `blueprints_backup/[timestamp]/` folders\n\n## Metadata Structure\n\n```json\n{\n  \"version\": \"2.0\",\n  \"lastUpdated\": \"2025-01-24T10:00:00Z\",\n  \"files\": {\n    \"First Factory/Blueprint1.sbp\": {\n      \"fileId\": \"uuid-1234-5678-9abc\",\n      \"globalStatus\": \"active\",\n      \"deletedBy\": null,\n      \"deletedTimestamp\": null,\n      \"lastKnownHash\": \"SHA256...\",\n      \"devices\": {\n        \"DESKTOP-ABC123\": {\n          \"status\": \"active\",\n          \"hash\": \"SHA256...\",\n          \"lastModified\": \"2025-01-24T10:00:00Z\",\n          \"lastSeen\": \"2025-01-24T10:00:00Z\"\n        }\n      },\n      \"versions\": [\n        {\n          \"hash\": \"SHA256...\",\n          \"timestamp\": \"2025-01-24T10:00:00Z\",\n          \"device\": \"DESKTOP-ABC123\",\n          \"action\": \"create\"\n        }\n      ]\n    }\n  },\n  \"devices\": {\n    \"DESKTOP-ABC123\": {\n      \"lastSync\": \"2025-01-24T10:00:00Z\",\n      \"lastKnownFiles\": {\n        \"First Factory/Blueprint1.sbp\": \"SHA256...\"\n      }\n    }\n  }\n}\n```\n\n## Management Commands\n\n```powershell\n# View task status\nGet-ScheduledTask -TaskName 'SatisfactoryBlueprintSync' | Get-ScheduledTaskInfo\n\n# Run sync manually\nStart-ScheduledTask -TaskName 'SatisfactoryBlueprintSync'\n\n# Disable sync temporarily\nDisable-ScheduledTask -TaskName 'SatisfactoryBlueprintSync'\n\n# Re-enable sync\nEnable-ScheduledTask -TaskName 'SatisfactoryBlueprintSync'\n\n# Uninstall scheduled task\nUnregister-ScheduledTask -TaskName 'SatisfactoryBlueprintSync' -Confirm:$false\n```\n\n## Manual Sync\n\nTo run the sync manually without the scheduled task:\n```powershell\n# Default bidirectional sync\npowershell.exe -ExecutionPolicy Bypass -File \"C:\\Scripts\\SatisfactorySync\\Sync-SatisfactoryBlueprints.ps1\"\n\n# Push only (local to cloud)\npowershell.exe -ExecutionPolicy Bypass -File \"C:\\Scripts\\SatisfactorySync\\Sync-SatisfactoryBlueprints.ps1\" -SyncMode LocalToCloud\n\n# Pull only (cloud to local)\npowershell.exe -ExecutionPolicy Bypass -File \"C:\\Scripts\\SatisfactorySync\\Sync-SatisfactoryBlueprints.ps1\" -SyncMode CloudToLocal\n\n# Skip OneDrive pinning\npowershell.exe -ExecutionPolicy Bypass -File \"C:\\Scripts\\SatisfactorySync\\Sync-SatisfactoryBlueprints.ps1\" -SkipOneDrivePinning\n\n# Custom version history limit (default is 10)\npowershell.exe -ExecutionPolicy Bypass -File \"C:\\Scripts\\SatisfactorySync\\Sync-SatisfactoryBlueprints.ps1\" -MaxVersionHistory 20\n\n# Or use the VBScript wrapper for silent execution\nwscript.exe \"C:\\Scripts\\SatisfactorySync\\Sync-SatisfactoryBlueprints.vbs\"\n```\n\n## Troubleshooting\n\n### Sync not running\n1. Check task status: `Get-ScheduledTask -TaskName 'SatisfactoryBlueprintSync'`\n2. Review logs at: `$env:OneDrive\\Documents\\Satisfactory\\logs\\`\n3. Verify Windows PowerShell is available: `powershell.exe -Command \"Get-Host\"`\n\n### Files not syncing\n1. Check source folder exists: `%LocalAppData%\\FactoryGame\\Saved\\SaveGames\\blueprints\\`\n2. Ensure OneDrive is running and syncing\n3. Review metadata.json for device entries\n4. Check file permissions on both source and destination\n\n### Deleted files reappearing\n- This is prevented by the metadata tracking system\n- Check metadata.json to ensure your device is properly registered\n- Files are moved to blueprints_backup with timestamps, not deleted\n\n## 🎮 Game Information\n\n- **Satisfactory** is a first-person open-world factory building game by Coffee Stain Studios\n- [Official Website](https://www.satisfactorygame.com/)\n- [Steam Store Page](https://store.steampowered.com/app/526870/Satisfactory/)\n- [Epic Games Store](https://store.epicgames.com/en-US/p/satisfactory)\n- [Satisfactory Wiki](https://satisfactory.wiki.gg/)\n\n## 📝 Notes\n\n- Blueprints require the **Mark 1 Blueprint Designer** to be unlocked in-game\n- Each blueprint consists of two files: `.sbp` (data) and `.sbpcfg` (config)\n- Save game folders are created automatically as needed\n- Empty folders are cleaned up automatically\n- The scheduled task uses Interactive logon with VBScript wrapper for completely silent execution\n\n## 🤝 Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## 📄 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## 🙏 Acknowledgments\n\n- [Coffee Stain Studios](https://www.coffeestainstudios.com/) for creating Satisfactory\n- The Satisfactory community for blueprint sharing inspiration\n- Microsoft for PowerShell and OneDrive integration\n\n## ⚠️ Disclaimer\n\nThis tool is not affiliated with, endorsed by, or connected to Coffee Stain Studios or Satisfactory. Satisfactory is a trademark of Coffee Stain Studios AB.","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdkmaker%2Fsatisfactory-sync-onedrive","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdkmaker%2Fsatisfactory-sync-onedrive","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdkmaker%2Fsatisfactory-sync-onedrive/lists"}