Skip to content

feat: add bulk profile import from mixed-text clipboard - #262

Open
m146979 wants to merge 2 commits into
appshubcc:mainfrom
m146979:feature/bulk-import-profiles
Open

feat: add bulk profile import from mixed-text clipboard#262
m146979 wants to merge 2 commits into
appshubcc:mainfrom
m146979:feature/bulk-import-profiles

Conversation

@m146979

@m146979 m146979 commented Jul 10, 2026

Copy link
Copy Markdown

Summary

Adds a Bulk Import option to the "Add Profile" menu that lets users paste any block of text (e.g. a Telegram message, a webpage snippet, a notes dump) and automatically detects all subscription/proxy URLs inside it, then imports them in one go.


Changes

lib/views/profiles/bulk_import_profiles.dart (new)

  • Multi-line text field for pasting arbitrary mixed content
  • Live URL extraction via regex — detects http(s), ftp, vmess, vless, ss, trojan, hysteria/hysteria2, tuic, wg/wireguard schemes
  • Deduplication of extracted URLs
  • Checklist UI — all detected URLs pre-selected; user can deselect any
  • "Paste from Clipboard" shortcut button
  • Sequential import with per-item ✅ / ❌ status shown in real time
  • Edit button per URL — opens the existing EditProfileView sheet for customisation
  • Result summary line after completion (e.g. "3 imported, 1 failed")

lib/views/profiles/add_profile.dart (modified)

  • Added a new Bulk Import ListItem entry at the bottom of the Add Profile menu
  • Tapping opens BulkImportProfilesView inside the existing AdaptiveSheetScaffold

arb/intl_en.arb (modified)

  • Added 9 new i18n keys: bulkImport, bulkImportDesc, bulkImportTitle, bulkImportPaste, bulkImportDetected, bulkImportNoUrls, bulkImportStart, bulkImportAdding, bulkImportResult

How to use

  1. Open Profiles → Add Profile
  2. Tap Bulk Import
  3. Paste any text — URLs are detected instantly
  4. Deselect any you don't want, then tap Import Selected

m146979 added 2 commits July 10, 2026 13:21
- Add BulkImportProfilesView widget with:
  - Multi-line text area for pasting arbitrary mixed text
  - URL extraction via regex (http/https/ftp + proxy schemes)
  - Interactive checklist to select/deselect detected URLs
  - Sequential profile add with per-item success/fail status
  - "Paste from clipboard" shortcut button
  - Supports http, https, ftp, vmess, vless, ss, trojan,
    hysteria, hysteria2, tuic, wg, wireguard schemes
- Add 'Bulk Import' ListItem entry in AddProfileView
- Add i18n keys to intl_en.arb:
  bulkImport, bulkImportDesc, bulkImportTitle,
  bulkImportPaste, bulkImportDetected, bulkImportNoUrls,
  bulkImportStart, bulkImportAdding, bulkImportDone,
  bulkImportResult
- Add bulk import UI component with URL detection from mixed text
- Support multiple proxy URI schemes (vmess, vless, ss, trojan, etc.)
- Add localization for English, Russian, Simplified Chinese, and Traditional Chinese
- Update message indices across all locale files to accommodate new bulk import strings
- Fix regex pattern in bulk_import_profiles.dart to use raw string for better readability
- Remove unused path_provider_foundation plugin from macOS GeneratedPluginRegistrant
- Add pubspec.lock to .gitignore for Flutter version management
@appshubcc

Copy link
Copy Markdown
Owner

Has it been verified and tested yet?

@appshubcc
appshubcc force-pushed the main branch 2 times, most recently from bb605a0 to 570c649 Compare July 18, 2026 17:07
@appshubcc
appshubcc force-pushed the main branch 2 times, most recently from 95bde57 to c0bb574 Compare August 13, 2026 04:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants