Skip to content

Latest commit

 

History

History
26 lines (18 loc) · 373 Bytes

DropToPlugin.md

File metadata and controls

26 lines (18 loc) · 373 Bytes

Drop to plugin

Requires adding metadata for the accepted types.

Example

opens paths and URLs dropped on the plugin.

#!/bin/bash

# <bitbar.droptypes>filenames,public.url</bitbar.droptypes>

if [ "$1" = "-filenames" ]; then
  shift
  open "$@"
  exit
fi

if [ "$1" = "-public.url" ]; then
  open "$2"
  exit
fi

echo "Drop here"