2 releases

new 0.1.1 Feb 1, 2025
0.1.0 Jan 23, 2025

#949 in Command line utilities

Download history 112/week @ 2025-01-22 121/week @ 2025-01-29

233 downloads per month

Custom license

315KB
464 lines

DotPorter 🔄

Rust License: MIT Crates.io Version Crates.io Size Crates.io Total Downloads

A powerful Rust-based tool for managing and synchronizing your dotfiles and packages across different machines.

dotporter Crate

The dotporter crate is now published on crates.io. You can add it to your project by including the following in your Cargo.toml:

[dependencies]
dotporter = "0.1"  # Replace "0.1" with the latest version if needed

Or just install it globally with

cargo install dotporter

📁 Tool Structure

Folder Description
📂MANUAL_BACKUP Storage for manual backup files (legacy version)
📂LEGACY_DEPRECATED Archive of old scripts for reference
📂dotfiles Synchronized configuration files (auto-populated)
📂Packages Package management and backup files

🚀 How does it work

New Released Version (Rust-based)

  1. Run the following command:
cargo run --bin Dotporter

This will automatically create a config file in your home directory:

~/dotporter/backup_config.toml
📸 Configuration Preview

Config Preview

The configuration file can be customized to include or exclude:

  • Package managers
  • Folders
  • Specific files

After completion, two main folders will be created:

  • 📁 Dotfiles
  • 📁 Packages
📸 Result Structure

Dotfiles Structure Packages Structure

Legacy Version

Click to expand legacy version details

The root directory contains backup references for:

  • 🐚 Shell Settings: Themes and plugins for Oh My Zsh
  • 📄 .zshrc: Zsh configuration
  • 🎨 personal-zsh-theme: Custom theme inspired by daivasmara
  • ⚙️ settings.zip: PHPStorm configuration

Scripts Usage

  1. Backup your packages:
chmod a+x ./scripts/backup-packages.sh
./backup-packages.sh
  1. Restore on new machine:
chmod a+x ./scripts/packages/brew-bulk-install.sh
chmod a+x ./scripts/packages/packages-reinstall.sh
./brew-bulk-install.sh
./packages-reinstall.sh

🛠 Dependencies

Required tools for the new machine:

Tool Purpose
🍺 Brew Package Manager for macOS
💎 RubyGems Ruby Package Manager
📦 Node Package Managers Choose from:Yarn, NPM, BUN, PNPM
🎼 Composer PHP Package Manager
🐍 Pip Python Package Manager
🦀 Cargo Rust Package Manager
📜 Atuin Shell History Manager
🐚 ZSH Shell (Optional)

⚠️ Important Notes

  • Beta Feature: Package installation binary is available but untested
cargo run --bin install
  • Composer Packages: Consider manual composer.json copy and install
  • Config Backup: Current release focuses on configuration backup

🤝 Contributing

Feel free to:

  • Submit issues
  • Create pull requests
  • Suggest enhancements
  • Made with ❤️ by 📧 hamzahasbi

Dependencies

~2.2–9.5MB
~90K SLoC