# Alfred Preferences Sync

This repository contains synchronized Alfred preferences, including workflows, snippets, and configurations. The setup allows for easy backup and synchronization across multiple Mac machines.

## Overview

Alfred is a productivity application for macOS. This repository uses git to version-control and sync:

- **Workflows** - Custom automation scripts and workflows
- **Snippets** - Text expansion collections organized by theme
- **Preferences** - Alfred application settings

## Repository Structure

```
AlfredPrefs/
├── Alfred.alfredpreferences/     # Main Alfred preferences package
│   ├── workflows/                # Alfred workflows (UUID directories)
│   ├── snippets/                 # Text snippet collections
│   ├── preferences/              # General settings
│   ├── resources/                # Icons and assets
│   └── remote/                   # Sync metadata
└── alfred-sync.sh                # Sync script
```

## Cloning to a New Machine

1. Clone this repository:
   ```bash
   git clone <repository-url> ~/Sync/AlfredPrefs
   ```

2. Symlink to Alfred's expected location (if needed):
   ```bash
   ln -s ~/Sync/AlfredPrefs/Alfred.alfredpreferences ~/Library/Application\ Support/Alfred/Alfred.alfredpreferences
   ```

3. Restart Alfred to load the preferences

## Syncing Changes

After making changes to Alfred workflows or snippets:

```bash
cd ~/Sync/AlfredPrefs
./alfred-sync.sh
```

This will:
- Stage all changes
- Create a timestamped commit
- Push to the remote repository

## Workflows Included

| Workflow Name | Description |
|--------------|-------------|
| 無腦生密碼 | Password generator (easy to read/all characters) |
| TextTaiwanizer | Convert text to Taiwan-style Chinese |
| 盤古之白自動加空格 | Auto-add spaces between Chinese and English |
| 使用Prettier自動格式化程式碼 | Prettier code formatter |
| 使用urldecode解碼URL編碼字串 | URL decoder |
| Office 滅證 | Office metadata cleaner |

## Snippet Collections

- **術語速查字典** - Technical terminology (SQL, Oracle, Docker, etc.)
- **中文輸出速查** - Chinese text expansion shortcuts
- **特殊字元輸出集** - Special character collections
- **常用密碼快速鍵** - Password shortcuts
- Various tool-specific collections (Homebrew, Docker, VS Code, etc.)

## Caution

Some snippet collections contain sensitive information (e.g., `topsecret/`). Be mindful when committing and sharing this repository.

## License

Personal use only.
