Skip to content

Enhance Nemo scripts to support multi-selection of files and directories#10

Merged
wilmerm merged 3 commits intomainfrom
copilot/fix-8
Aug 10, 2025
Merged

Enhance Nemo scripts to support multi-selection of files and directories#10
wilmerm merged 3 commits intomainfrom
copilot/fix-8

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Aug 9, 2025

This PR enhances the Nemo integration scripts to support multi-selection of files and directories, allowing users to perform cryptographic operations on multiple items simultaneously.

Changes Made

Core Functionality

  • Multi-selection support: All three Nemo scripts (encrypt.sh, decrypt.sh, secure-delete.sh) now read from the NEMO_SCRIPT_SELECTED_FILE_PATHS environment variable to process multiple selected files
  • Backward compatibility: Scripts maintain full compatibility with single file command line arguments
  • Batch processing: Multiple files are processed in a single operation with consolidated feedback

User Interface Improvements

  • Adaptive dialog text:
    • Single file: "Ingresa la clave para cifrar 'filename':"
    • Multiple files: "Ingresa la clave para cifrar 5 archivos seleccionados:"
  • Enhanced error handling: Individual error reporting for each file, with graceful handling of non-existent files
  • Special character support: Properly handles filenames with spaces and special characters

Technical Implementation

  • Scripts now iterate through all selected files using bash while read loops
  • Robust file existence checking before processing
  • Maintains Spanish UI language consistency
  • Uses fallback command detection (cryptshield command or Python module)

Usage Examples

Before (single file only):

# Could only process one file at a time
Right-click → Scripts → encrypt.sh (processes only one file)

After (multi-selection):

# Select multiple files with Ctrl+click or Shift+click
# Right-click → Scripts → encrypt.sh (processes all selected files)

Testing

  • Comprehensive test coverage including edge cases (empty selection, non-existent files, special characters)
  • Validated backward compatibility with existing single-file workflows
  • Tested with various file types and directory structures
  • All error scenarios properly handled with appropriate user feedback

The enhancement significantly improves workflow efficiency by allowing users to encrypt, decrypt, or securely delete multiple files at once directly from Nemo's context menu.

Fixes #8.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits August 9, 2025 15:06
Co-authored-by: wilmerm <44853160+wilmerm@users.noreply.github.com>
Co-authored-by: wilmerm <44853160+wilmerm@users.noreply.github.com>
Copilot AI changed the title [WIP] Allow multi-selection in Nemo scripts Enhance Nemo scripts to support multi-selection of files and directories Aug 9, 2025
Copilot AI requested a review from wilmerm August 9, 2025 15:10
@wilmerm wilmerm marked this pull request as ready for review August 10, 2025 10:06
@wilmerm wilmerm merged commit a9e3848 into main Aug 10, 2025
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.

Allow multi-selection in Nemo scripts

2 participants