Brett’s PopClip Extensions
- Installation
- Extensions
- Blockquote
- BulletList
- CheckURLs
- Comment
- Code
- CopyPLUS
- FixPoorlyObscuredEmails
- Increment Templated
- Markdown to Mindmap
- Markdownify
- NumberedList (deprecated)
- OpenURLS
- CopyURLS
- Outdent
- SkypeCall
- HardWrap
- Too Many Wrappers
- URLEncode
- Editor
- CriticMarkup
- WebMarkdown
- Twitterify
- LinkCleaner
- CopyCleanLinks
- Sum
- DefineAbbr
- PoorText
- SearchLink
- nvUltra
- Download
- Changelog
This is a collection of my own extensions for the Mac app PopClip. It gives you a popup when you select text, a la iOS, and lets you perform various operations on/with it.
Many of my extensions are Markdown-related, but there are a few other goodies in there, too.
Installation
To install from the download package, just unzip and double-click the extensions you want to use. To install from the source code, just make sure the extension of a folder is .popclipext
and double click it in Finder.
If an extension is already installed, double clicking the downloaded one will just update the existing extension. There’s no need to uninstall before moving on to the latest fun.
Current release version: 1.44.3 (source code)_
Extensions
The extensions currently included in the bundle. Some are available elsewhere as well, but this collection will always be the most up-to-date versions.
Blockquote
Turn indented text (or any text) into nested Markdown blockquotes.
- Clicking adds a “>” for each indentation level in the selected text
- Command-click to decrease quote level
- Command-Option-click key to remove all quoting
When adding quote levels, multiple line breaks between lines creates separate block quotes (by design). If there’s a single blank line between to paragraphs, they’ll be joined together as paragraphs within a blockquote. More than one starts a new quote.
BulletList
PopClip extension to turn lines of text into Markdown bullet items. Indentation is handled as nested lists and existing markers are overwritten (numbered list becomes bullet list).
Numbered lists
Holding Option (⌥) while clicking the button for the extension in the PopClip bar will create/update a numbered list instead. When the list is already a numbered list, it will be re-numbered to fix any gaps or out-of-order numbering within nest levels.
Clear list formatting
Holding Command (⌘) while clicking will remove all list prefixes.
Bullet format
When you install this extension, you’ll get an options page where you can select the type of bullet you prefer for unordered lists. This can be accessed again later by clicking the pencil button at the bottom of the list, then clicking the gear button next to the BulletList extension.
CheckURLs
Show a popup preview for each URL in selected text. Used for confirming the output of scripts like SearchLink without switching to the browser.
Links are shown sequentially in the order they’re found. If a URL is changed by following links in the preview and pressing “OK”, the selected text will be updated with the final URL. Because of this, duplicate links in the text are all previewed so they can be modified individually.
Comment
Adds comment tags around or before text:
- Default: HTML Comment
- Hold Option: CSS Comment (
/* block of text */
) - Hold Command: Hash Comment (
# before each line
) - Hold Command-Option: Slash comment (
// before each line
)
Code
Turn selected text into Markdown inline code or a code block.
Detects whether there are multiple lines:
- if not, it surrounds the input in backticks
- if so, it indents the entire block by one tab.
When creating an inline code block, it will also detect whitespace at the beginning and end of the selection and make sure that it’s excluded from the surrounding backticks.
CopyPLUS
PopClip extension to append the selection to the current contents in the clipboard. This is a duplicate of an existing extension (Append) with just slightly better UTF-8 handling, and modifier key handling for copying with and without linebreaks and whitespace.
- Hold Command (⌘) when clicking to add an extra line break between entries.
- Hold Option (⌥) to append with no extra whitespace.
FixPoorlyObscuredEmails
Fixes emails obscured in a “support AT mydomain DOT com” fashion.
Hold Option to also open a new email compose window for each matched address. This feature does not require edit capability in the current field.
Increment Templated
PopClip extension to increment and repeat templated text. See the extension README for details.
Markdown to Mindmap
Takes a selection of plain text containing markdown headlines, list items and paragraphs and converts it into a format ready for pasting into a mind mapping application (such as MindNode, MindManager or MindMeister) as separate nodes/topics.
Markdownify
This extension converts selected HTML text to Markdown using html2text by Aaron Swartz. Reference-style links are used and the references are placed after the text. Wrapping is disabled.
The extension shows up in PopClip as “2MD”.
NumberedList (deprecated)
PopClip extension to turn lines of text into Markdown numbered items. Will sort and update an existing numbered list as well, and convert bullets on list items to numbers.
This is only here if you want a separate button for numbered lists. Otherwise you can just use BulletList and hold down option to create an ordered list instead.
OpenURLS
This extension searches selected text for urls (http or custom handlers) and opens all urls in their default applications.
The default OpenInChrome extension is Chrome-specific and only works with a single URL. This extension allows as many urls as you can select and will open whatever browser your system has assigned to the handler. This includes nvalt:// and txmt:// links, as well as http:// links. If you use something like Choosy it will open them through that.
Turned out to be more useful to me to just have it handle http links, detect links without protocols, and open those in my default browser.
CopyURLS
Duplicate of OpenURLS, but copies urls to the clipboard, one link per line, instead of opening in browser.
Outdent
Fully outdents the selection, maintaining nested indentation.
SkypeCall
Detect phone numbers in the selection and call the first one using Skype.
HardWrap
Add hard wrapping to paragraphs. Default wrap column is 80, hold down Option to wrap at an alternate column (modify both in the extension options). Hold down command to unwrap text, removing line breaks between lines but preserving multiple lines between paragraphs.
- Clicking wraps at ruler, default 80 characters
- Option-click to wrap to alternate width
- Command-click to unwrap text
Too Many Wrappers
Allows the definition of three custom “wrappers,” prefixes and suffixes that will surround selected text. They’re triggered, respectively, by clicking with the Option key, Command key or no modifier key held down.
Think of it as a custom version of the comments plugin. I find it quite handy for adding <mark>
, <ins>
and <del>
tags to text when editing for others.
When installing the extension, the options will appear. They can be accessed again by going into edit mode in the plugins dropdown and clicking the gear icon next to “Wrappers.”
URLEncode
Just URL encodes (percent encoding) the selected text using Perl.
Also available at Pilot Moon, same extension.
Editor
- No modifier:
<mark>
(highlight) - Control:
<ins datetime></ins>
(insertion) - Command:
<del datetime></del>
(deletion) - Option:
<!-- -->
(comment)
CriticMarkup
Allows the quick insertion of CriticMarkup syntax. Optionally fill in a signature to have a comment included after every insert, deletion or change with your initials or name.
- No modifier: Highlight
- Command: Deletion
- Control: Insertion
- Control-Option: Change
- Option: Comment
WebMarkdown
Also known as WebMD, this extension shows up when you select text on a web page. Clicking it will convert the selected headlines, text and links (including image links) to Markdown in your clipboard.
This extension now uses Gather. If you don’t have it installed it will offer to do so for you.
Twitterify
Convert all @names and #tags to Markdown or HTML links. You can set the default link type in the extension’s options, and manually switch to the other type by holding down Option when running it.
LinkCleaner
PopClip extension to lengthen and clean URLs.
Option: clean all query strings (default: only clean Google UTM strings) Command: Output just the resulting URL(s) Command-Option: Output just URL(s) with query strings stripped
CopyCleanLinks
PopClip extension to lengthen and clean URLs. Duplicate of LinkCleaner, but only copies results to the clipboard.
Option: clean all query strings (default: only clean Google UTM strings) Command: Output just the resulting URL(s) Command-Option: Output just URL(s) with query strings stripped
Sum
Detect all numbers in selection and total them. Allows decimal places (using .
or ,
as separator) and negative numbers. Result is copied to clipboard.
Use the options “Separator” and “Decimal Delimiter” to define characters used in your locale for separating thousands and decimal places, respectively.
DefineAbbr
PopClip extension to search textingabbreviations.ca for the selected string.
PoorText
Strips rich text formatting from selection. There are probably multiple others that do this, but it’s so easy I just made it myself.
SearchLink
Runs the SearchLink service on selected text. Requires that searchlink be installed in ~/Library/Services.
nvUltra
Adds the selected text to a new note in nvUltra. You can configure which notebook to use when installing the extension.
Download
Brett's PopClip Extensions v1.44
Download Brett's PopClip Extensions v1.44
A few PopClip extensions for Markdown writing and other useful tools
Published 11/30/14.
Updated 01/24/23. Changelog
The GitHub repository for all of my extensions is here.
Changelog
Click to expand
1.44
- Fix SearchLink extension
1.43
- If SearchLink isn’t installed, install it when running the SearchLink extension
1.42
- Fix nvUltra extension
- Add SearchLink extension
1.41
- Update WebMarkdown to allow for gather installs in /opt/homebrew/bin.
1.40
- Remove the popcliphtml2text CLI from WebMarkdown that was causing “malicious software” warnings. Now offers to download and install using the signed and notarized package.
1.38
- Fix a couple of bugs and improve output of html2text for WebMarkdown
1.35
- Convert WebMarkdown to use Swift-based HTML2Text, avoiding need for Python executable
1.34
- Fix for WebMarkdown, change to python3 and update html2text
1.33
- Fix for bad option default type in some of the plists.
1.31
- Increment Templated updates/fixes
1.28
- Add “Increment Templated” extension
1.27
- Add “HardWrap” extension
1.25
- Replace PreviewURL with CheckURLs
- Allows results from preview navigation to modify selected text
- Better icon
1.24
- Updated PreviewURL
- Ignore URLs without http(s) protocol
- Handle multiple URLs
- Center preview pane on display
1.19 — 1.23
- stupid commits because I’m having trouble with the build script. Don’t mind me.
1.18
- Quick little format stripper (PoorText)
1.17
- Added “DefineAbbr” extension
1.16
- Updated (rewritten) blockquote extension
1.15
- Added “Sum” extension
1.14
- Added LinkCleaner and CopyCleanLinks extensions
1.12
- Added Twitterify extension.
1.11
- Added the WebMarkdown extension.
1.10
- Updated OpenURLS
- Better regex for extracting URLs
- Hold down Option to combine lines and fix broken urls
- This can cause issues with full urls on consecutive lines, but is handy for a single broken link.
- Leaves leading space on lines, so urls broken with an indent are still screwed. Ran into too many problems trying to parse around that.
-
Added CopyURLs
Duplicate of OpenURLs, but copies a plain, newline-separated list to the clipboard
- Added FixPoorlyObscuredEmails
- Fixes “me AT here DOT com” style email obfuscations
- Hold Option to compose new email for matched addresses
1.8
- Blockquote:
- Handle line breaks better
- Command-click to decrease quote level
- Command-Option-click key to remove all quoting
- don’t quote reference link definitions
- BulletList: Bullet type configuration options, Command modifier to remove list formatting
- CopyPlus: Option modifier to concatenate strings with no extra whitespace
- Credits block for all extensions
- URLEncode extension (also available at Pilot Moon)
1.7
- Outdent: Command-click to outdent all lines fully
- Too Many Wrappers: Removed Shift-click options as they were breaking stuff.
- CopyPlus: Command-click to add extra linebreak between entries
Speaking of Brett's PopClip Extensions…
- PopClip extensions update
- Web Excursions for November 25, 2022
- PopClip WebMarkdown fix and other codesigning adventures
- PopClip extensions: WebMarkdown fix
- Improvements for the Increment Templated Service (+PopClip)
- HardWrap extension for PopClip
- SearchLink: Checking your work
- The Top 20 Apps not in my Dock
- PopMaker 0.3
- Best of 2017: Nerding out on macOS
- An update to PopMaker extension generator for PopClip
- Invoking PopClip on an existing selection
- PopMaker: a PopClip extension generator
- Sum: PopClip extension
- Link cleaning extensions for PopClip
- Twitterify Popclip Extension
- Web Markdownifier for PopClip
- Wallflowers: my favorite OS X augmentations
- Yes, I spend too much time tweaking PopClip
- Editor and CriticMarkup extensions for PopClip
- It's a blue period, but with PopClip instead of paint
- PopClip hacking
- Too many wrappers - a PopClip Extension
- Converting Markdown to a mind map
- CopyPLUS for PopClip
- Comment extension for PopClip
- SkypeCall extension for PopClip
- Web Excursions for March 25, 2013
- More Markdown for PopClip
- OpenURLS PopClip extension
- Markdownify extension for PopClip