--- name: minio-upload description: Upload files to MinIO obsidian bucket with configurable path support. Use when the user asks to upload files to MinIO, transfer to obsidian bucket specifically, upload markdown or other files to cloud storage, or specify custom subpaths within obsidian bucket --- # MinIO Upload Upload files to the MinIO obsidian bucket with flexible path configuration. ## Quick Start Upload a file to the default `main` path: ```bash .claude/skills/minio-upload/scripts/upload_to_obsidian.sh path/to/file.md ``` Upload to a custom subpath: ```bash .claude/skills/minio-upload/scripts/upload_to_obsidian.sh path/to/file.md "notes/2024" ``` ## Workflow 1. **Verify file exists** - Check that the source file is accessible 2. **Determine target path** - Use specified subpath or default to `main` 3. **Upload with mc** - Execute `mc cp` command to transfer file 4. **Confirm success** - Verify upload completed and report target location ## Path Configuration The script accepts an optional subpath argument: - **Default**: Files upload to `minio/obsidian/main/` - **Custom subpath**: Specify any subpath (e.g., `notes/2024`, `archive/old projects`) - **Nested paths**: Multi-level paths are supported (e.g., `notes/personal/journal`) The script automatically: - Appends the filename to the target path - Normalizes multiple slashes in paths - Uses the `minio` alias configured in mc ## Error Handling The script will: - Exit with error if file doesn't exist - Exit with error if no file argument provided - Propagate any mc command failures ## Resources ### scripts/upload_to_obsidian.sh Bash script that handles the upload process. Validates inputs, constructs the target path, and executes the mc copy command. **Key features:** - Default to `main` path when no subpath specified - Support nested subpaths with proper path normalization - Clear error messages for invalid inputs - Success confirmation with source and target paths