/home/alex/dev/fa-debug.applescript (1)

From RaySoft
#!/usr/bin/osascript
-- -----------------------------------------------------------------------------
-- fa-debug.applescript
-- =================
--
-- Project   Folder Actions
-- Scope     macOS
-- Copyright (C) 2024 by RaySoft, Zurich, Switzerland
-- License   GNU General Public License (GPL) 2.0
--           https://www.gnu.org/licenses/gpl2.txt
--
-- -----------------------------------------------------------------------------

on adding folder items to this_folder after receiving these_items
  tell application "Finder"
    set this_folder_posix to quoted form of POSIX path of this_folder as text
  end tell

  set these_items_posix to {}

  repeat with this_item in these_items
    set end of these_items_posix to quoted form of POSIX path of this_item
  end repeat

  set text item delimiters to " "

  do shell script "${HOME}/dev/fa-debug.sh " ¬
    & this_folder_posix & " " & (these_items_posix as text)
end adding folder items to

-- ----------------------------------------------------------------------------

Usage