Cross-platform boot OS selector for Linux, Windows, and macOS
Project description
OS Flip 🌀
A multi-platform script to view and switch your default boot OS across Linux, Windows, and macOS.
✨ Overview
OS Flip is a cross-platform Python utility to manage boot preferences on dual-boot or multi-boot systems. It allows you to:
- 🔍 View all bootable OS entries
- ✅ Set a default OS for future boots
- 🔁 Temporarily Flips into another OS (“Flip”)
It works on:
- 🐧 Linux (GRUB-based)
- 🪟 Windows (
bcdedit) - 🍎 macOS (
bless) – ⚠️ experimental and not fully tested
Whether you're switching between Linux and Windows or managing a Boot Camp setup, OS Flip offers a simple, colorful terminal UI to handle it.
⚙️ Features
- 🧠 Auto-detects operating system
- 🔍 Lists all available boot entries
- ✅ Sets permanent default OS
- 🔁 Flips (reboots) temporarily into another OS
- 📁 Logs activity to platform-specific log file
📦 Requirements
🐧 Linux:
- Python 3
- GRUB2 bootloader
update-gruborgrub2-mkconfigos-prober- Run with
sudoor as root
🪟 Windows:
- Python 3
- Run as Administrator
bcdedit(pre-installed on Windows)
🍎 macOS (experimental):
- Python 3
diskutil,systemsetup,bless- Run with
sudo
✅ Install Python dependency:
pip install colorama
🚀 Usage
Run the script with elevated privileges:
On Linux/macOS:
sudo python3 os_flip.py
On Windows:
Run Command Prompt or PowerShell as Administrator, then:
python os_flip.py
🧪 Example Output
____ _____ ______ _ _____ _____
/ __ \ / ____| | ____| | |_ _| __ \
| | | | (___ ___ | |__ | | | | | |__) |
| | | |\___ \ | __| | | | | | ___/
| |__| |____) | | | | |____ _| |_| |
\____/|_____/ |_| |______|_____|_|
Welcome to OS FLIP
By - AK (Linux)
ℹ️ Backed up GRUB config to /etc/default/grub.bak.1753056275
✅ os-prober enabled.
ℹ️ Updating GRUB entries... done
📜 Available Boot Entries:
1. Windows Boot Manager (on /dev/nvme0n1p1) (Current Default)
2. Fedora Linux
⚙️ Options:
1. Set default boot OS
2. Flip OS
3. Exit
📂 Log Files
Activity is logged to a file based on your OS:
- Linux/macOS:
/tmp/os_flip_<username>.log - Windows:
%TEMP%\os_flip_<username>.log
Useful for debugging or audit trails.
📌 Notes
- Linux: Edits
/etc/default/grub, then runsupdate-gruborgrub2-mkconfig - macOS: Uses
blessto set the startup disk (requires SIP-safe paths) - Windows: Uses
bcdeditto read/set boot configuration - The script auto-launches in a new terminal if not already interactive
- GRUB backup is created before changes (
/etc/default/grub.bak.<timestamp>)
🧪 Tested Platforms
| OS | Status |
|---|---|
| Ubuntu | ✅ Confirmed |
| Fedora | ✅ Confirmed |
| Windows 10/11 | ✅ Confirmed |
| macOS (Intel) | ⚠️ Experimental |
🛑 Disclaimer
Use at your own risk. Modifying bootloader settings can affect system startup. Ensure you understand the implications, especially on production or encrypted systems.
👨💻 Author
AK – github.com/AKris15
📜 License
MIT License (modified)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file os_flip-1.0.1.tar.gz.
File metadata
- Download URL: os_flip-1.0.1.tar.gz
- Upload date:
- Size: 9.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
49936c039561c2057600841120c87f5df700bcc7a27d69f097085cf406e51858
|
|
| MD5 |
c5bf19f84848bddee31470b8d006b30c
|
|
| BLAKE2b-256 |
6aaaac9047735722ed8706d3897d27234ad35c52832baecaa1db7f668626b103
|
File details
Details for the file os_flip-1.0.1-py3-none-any.whl.
File metadata
- Download URL: os_flip-1.0.1-py3-none-any.whl
- Upload date:
- Size: 9.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
74f8d956685da0af44597f8903745a0e5c6a4a1c30653357294d81daf2580374
|
|
| MD5 |
69c1808b3e10bdbef514cfa1925367cd
|
|
| BLAKE2b-256 |
c58eba0f7a031e358c77e7cd920a33d553c219c1c41e38c6d41055da4e07336a
|