pilotmoon / PopClip-Extensions

Source code extensions in the official PopClip Extensions directory.

Home Page:https://www.popclip.app/extensions/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Is there any limitation when install from snippets ?

NamekMaster opened this issue · comments

I create a snippet as below:

# popclip abc
name: Color Preview
icon: square filled C
actions:
  - title: RGB HEX
    icon: square filled RGB
    regex: ^#[0-9a-fA-F]{6}$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: RGBA HEX
    icon: square filled RGBA
    regex: ^#[0-9a-fA-F]{8}$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: ARGBA HEX
    icon: square filled ARGB
    regex: ^#[0-9a-fA-F]{8}$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: RGB
    icon: square filled RGB
    regex: ^rgb\([0-9.,% ]+\)$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: HLS
    icon: square filled HLS
    regex: ^hls\([0-9.,% ]+\)$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: HLSA
    icon: square filled HLSA
    regex: ^hlsa\([0-9.,% ]+\)$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"

When I select it, no install extension option shown on the popup, but it show install option after I remove any two items, like this:

# popclip abc
name: Color Preview
icon: square filled C
actions:
  - title: RGB HEX
    icon: square filled RGB
    regex: ^#[0-9a-fA-F]{6}$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: RGBA HEX
    icon: square filled RGBA
    regex: ^#[0-9a-fA-F]{8}$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: ARGBA HEX
    icon: square filled ARGB
    regex: ^#[0-9a-fA-F]{8}$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"
  - title: RGB
    icon: square filled RGB
    regex: ^rgb\([0-9.,% ]+\)$
    applescript: tell application "Shortcuts Events" to run the shortcut named "Show color preview" with input "{popclip text}"

So Is there a limitation or bug ? I also tried with different actions, it seems the number of actions are not the only limitation.

Yes, there is a maximum of 1000 characters. You can increase it with

defaults write com.pilotmoon.popclip InceptionTextLimit -int 5000

then Quit and restart PopClip.