[QUIVER] Copy Selection to New Quiver Note

###Macro: [QUIVER] Copy Selection to New Quiver Note

####DOWNLOADS:

  1. Main Macro:
    [QUIVER] Copy Selection to New Quiver Note.kmmacros (71 KB)

  2. Sub-Macro:
    [SUB] BRW Get Page Title & URL from Safari, Chrome, or FF.kmmacros (19.7 KB)


VER:  2.0     Last Update: Thu, Jan 14, 2016 at   2:59 PM CT

**PURPOSE:  Copy Selection to New [Quiver][2] Note in a Code Cell**

   • **Source may be either a web page, or a script open in Script Editor**
   • **Both Code Cell Language & Notebook will be set based on language detected (can be changed in popup)**

AUTHOR:  @JMichaelTX at KM forum

HOW TO USE:

  1. If source is Web Page, first copy the URL to the clipboard,
      THEN select the text to be copied.
        • This is done so you can use the URL of a specific post on the page, rather than the page URL
        • If a URL is NOT on the clipboard, the page URL will be used.

  2. If the source is Script Editor, make sure the file is saved, 
      THEN select the text to be copied
         • The Source Date and URL will be set from the script file.

SETUP:
  • Change the default value for the Author in the Prompt for User Input (shown in yellow) to be the list of authors you commonly use.
  • Change the "Lang" variable default values as needed in the same Prompt.
  • Change or remove the Move to Notebook set of actions as needed.  Current it moves the Note to a Notebook with the same name as the Language.  See the actions highlighed in green.

**REQUIRES:**  
  1. Quiver
  2. KM Macro [SUB] BRW  Get Page Title & URL from Safari, Chrome, or FF

This is terrific. Thanks for sharing.

You're welcome. Let me know if you run into any bumps. :wink:

Thanks for sharing! I modified the macro a bit to better suite my needs, so I’m sharing it here in case anybody is interested.

Link: https://www.dropbox.com/s/0ahhjbcdiumavg1/quiver-keyboardmaestro-fnurl.kmmacros?dl=0

These macros can be used to copy selected text into new notes/cells in Quiver. The macros are split into three groups.

  • Quiver: Main contains initial keyboard triggers and sub-macros.
  • Quiver: New Cell contains macros for clipping into new Cells in existing notes
  • Quiver: New Note contains macros for clipping into new Notes.

Instructions:

  1. Select content in your app.
  2. Run macro (I have it bound to hyper+v see note below)
  3. Content + available details will be copied and used to create a markdown note in Quiver.

Note: I use a hyper key setup, i.e. I have bound my caps lock to work as a shift+alt+ctrl+cmd modifier key. See: http://brettterpstra.com/2015/12/18/a-hyper-key-that-can-still-yell/

Unfortunately, some of the macros need a rather long pause (1s) to let the GUI catch up. It would be faster if Quiver had AppleScript support.

The main differences from @JMichaelTX’s version are listed below.

Clip to new note / new cell in current note

Sometimes I clip more than one item from somewhere to a quiver note. So I added the option to clip to a new cell in the current note to that of clipping to a new note.

Just “one” clipping case

I removed the specialized Script Editor case. Now, when clipping, the source app, window title and URL if available is always captured from any app (well only support for Chrome, Firefox and Safari browsers for URLs) and the Note title, when creating a new note is the same for all sources.

If a URL is available it is added to the first line of the Markdown cell

No user dialog window

I didn’t need the author info etc as editable fields when I clip something.

Sub-palettes

After initializing the main palette, choices (new note/cell, then note/cell type) are made via subsequent keypresses in sub-palettes. E.g. clip to a new markdown note would be <init shortcut><new note key><markdown type>

Various restructuring

  • a few sub-macros for easier extension
  • prefix all variables used with QUIVER_

Thanks for sharing, @fnurl. The more choices/options for capturing stuff to Quiver the better!

1 Like

Hi there,

I am completely new to Keyboard Maestro and i found this only via Quiver's GitHub issue where you posted about this.

I have downloaded KM and installed your macros.

I am not sure how to run this.

Can help a newbie to KM?

Sure.

This is a fairly old macro, and is one that I no longer use. So I am not sure that it will still work with the current version of Quiver.

Having said that, did you see this in the Macro Release Notes:

HOW TO USE:

  1. If source is Web Page, first copy the URL to the clipboard,
    THEN select the text to be copied.
    • This is done so you can use the URL of a specific post on the page, rather than the page URL
    • If a URL is NOT on the clipboard, the page URL will be used.

  2. If the source is Script Editor, make sure the file is saved,
    THEN select the text to be copied
    • The Source Date and URL will be set from the script file.

Does that answer your question?