Metadata-Version: 2.4
Name: dotctl
Version: 1.0.2
Summary: Command Line Interface to manage (save, export, import) dot files in the form of profiles.
Author-email: Pankaj Jackson <pankajackson@live.co.uk>
License: MIT License
        
        Copyright (c) 2025 Pankaj Kumar Patel
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Project-URL: Homepage, https://github.com/pankajackson/dotctl
Project-URL: Bug Tracker, https://github.com/pankajackson/dotctl/issues
Project-URL: Source, https://github.com/pankajackson/dotctl
Keywords: dotfiles,config,settings,backup,dotfile-manager
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: End Users/Desktop
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: POSIX :: Linux
Classifier: Topic :: System :: Archiving :: Backup
Classifier: Topic :: Utilities
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: PyYAML
Requires-Dist: gitpython
Dynamic: license-file

# DotCtl

A CLI Tool to Manage DOT Files/Settings/Configurations.

## Features

- Save Profile: Save existing dot files/config/settings.
- Import Profile: Import existing dot files/config/settings from a `.plsv` file.
- Export Profile: Export and share existing dot files/config/settings to a `.plsv` file.
- Manage multiple profiles with ease.

## Installation

```sh
pip install dotctl
```

## CLI Guide

### Save Profile

```sh
dotctl save <profile_name>
```

**Example:**

```sh
dotctl save MyProfile
```

**Options:**

- `-f, --force` → Overwrite already saved profiles.
- `-c <path>, --config-file <path>` → Use external config file.
- `-e <env>, --env <env>` → Desktop environment (e.g., KDE).
- `-p <password>, --password <password>` → Sudo Password to authorize restricted data (e.g., `/usr/share`).
- `--include-global` → Include data from the global data directory (`/usr/share`).
- `--include-sddm` → Include SDDM data/configs (`/usr/share/sddm`, `/etc/sddm.conf.d`).
- `--sddm-only` → Operate only on SDDM configurations (**Note:** Requires sudo password).
- `--skip-sudo` → Skip all sudo operations.

### Remove Profile

```sh
dotctl remove <profile_name>
```

**Example:**

```sh
dotctl remove MyProfile
```

### List Profiles

```sh
dotctl list
```

### Apply Profile

```sh
dotctl apply <profile_name>
```

**Example:**

```sh
dotctl apply MyProfile
```

**Options:**

- `-p <password>, --password <password>` → Sudo Password for restricted data.
- `--sddm-only` → Apply only SDDM configurations (**Requires sudo password**).
- `--skip-global` → Skip data from the global directory (`/usr/share`).
- `--skip-sddm` → Skip SDDM configurations.
- `--skip-sudo` → Skip all sudo operations.

### Import Profile

```sh
dotctl import <profile_path>
```

**Example:**

```sh
dotctl import MyProfile.plsv
```

**Options:**

- `-p <password>, --password <password>` → Sudo Password for restricted data.
- `--config-only` → Apply only dot files/configurations (`~/.config`).
- `--data-only` → Apply only dot files/data (`~/.local/share`).
- `--sddm-only` → Apply only SDDM configurations (**Requires sudo password**).
- `--skip-global` → Skip global data.
- `--skip-sddm` → Skip SDDM configurations.
- `--skip-sudo` → Skip all sudo operations.

### Export Profile

```sh
dotctl export <profile_path>
```

**Example:**

```sh
dotctl export MyProfile.plsv
```

**Options:**

- `-p <password>, --password <password>` → Sudo Password for restricted data.
- `--config-only` → Export only dot files/configurations.
- `--data-only` → Export only dot files/data.
- `--sddm-only` → Export only SDDM configurations (**Requires sudo password**).
- `--skip-global` → Skip global data.
- `--skip-sddm` → Skip SDDM configurations.
- `--skip-sudo` → Skip all sudo operations.

### Wipe All Profiles

```sh
dotctl wipe
```

### Help

```sh
dotctl -h
dotctl <action> -h
```

**Example:**

```sh
dotctl import -h
```

### Version

```sh
dotctl -v
```

---

## Development & Publishing Guide

### Setup Development Environment

```sh
# Create virtual environment (optional but recommended)
python -m venv venv
source venv/bin/activate  # On Linux/macOS
venv\Scripts\activate  # On Windows

# Install dependencies
pip install -r requirements.txt
```

### Build the Package

```sh
python -m build
```

This will generate a `dist/` directory with `.tar.gz` and `.whl` files.

### Publish to TestPyPI

```sh
twine upload --repository testpypi dist/*
```

### Publish to PyPI

```sh
twine upload --repository pypi dist/*
```

---

## Who do I talk to?

- **Repo Owner/Admin:** Pankaj Jackson
- **Community Support:** Reach out via GitHub Issues
