exo_dissector_lua.sh 723 B

1234567891011121314151617181920212223242526
  1. #!/bin/bash
  2. # Set the directory containing your Lua dissector files
  3. DISSECTOR_DIR="./Dissector" # Change this if the directory is elsewhere
  4. # Set the output ZIP file name
  5. ZIP_FILE="exo_dissector_lua.zip"
  6. # Check if the Dissector directory exists
  7. if [ ! -d "$DISSECTOR_DIR" ]; then
  8. echo "Error: Dissector directory '$DISSECTOR_DIR' not found."
  9. exit 1
  10. fi
  11. # Create the ZIP file containing all Lua files from the Dissector directory
  12. echo "Creating ZIP file '$ZIP_FILE' from '$DISSECTOR_DIR'..."
  13. zip -r "$ZIP_FILE" "$DISSECTOR_DIR"/*.lua
  14. # Confirm the ZIP file was created
  15. if [ -f "$ZIP_FILE" ]; then
  16. echo "ZIP file '$ZIP_FILE' created successfully."
  17. else
  18. echo "Error: Failed to create the ZIP file."
  19. exit 1
  20. fi