Fixing Safari Setting for Keyboard Maestro

Back in April there was quite a kerfuffle over Smile Software's move to a subscription based payment for Text Expander. Dr Drang (@drdrang) has written a follow up to his earlier thoughts on the shift by Smile Software and moving his snippets to Keyboard Maestro. I've been making the same transition as well and hit my first road bump earlier this week.

One of my favorite KM macros is to use a keyboard short cut to clip information from a web page so I can put it into nvAlt for future reference. I recently ran across some information for Discord 1 that I wanted to save. So I did my keyboard short cut and...

Pfffttt

Nothing. Nothing copied and no error occurred. I looked at the macro to see if something changed with the recent update to Keyboard Maestro. I couldn't find any problems with the macro.

The script for the macro is:

tell application "Safari"
    activate
    set theURL to URL of front document
    set selectedText to (do JavaScript "(''+getSelection())" in document 1)
    set theTitle to name of front document
    set theDate to do shell script "date +'%Y-%m-%d'"
    set the clipboard to theTitle & return & return & theURL & return & return & selectedText & return & return & theDate as string
end tell

I fired up Script Editor to run the Applescript natively and boom... there was the error.

Looking into the problem it looks like a recent update reset some of Safari's safety features. You'll need to enable the Develop menu to get access to the setting. The setting to change is on the Develop menu:

You'll also be asked to confirm the change.

When I was done, I was able to get the clipping shortcut to work again.

Markdown Text 101 (Chat Formatting: Bold, Italic, Underline)  Discord

https://support.discordapp.com/hc/en-us/articles/210298617-Markdown-Text-101-Chat-Formatting-Bold-Italic-Underline-

Want to inject some flavor into your everyday text chat? You're in luck! Discord uses Markdown, a simple plain text formatting system that'll help you make your sentences stand out. Here's how to do it!

Just add a few characters before & after your desired text to change your text! I'll show you some examples:

italics = *italics*
bold  = **bold**
bold italics = ***bold italics***
strikeout = ~~strikeout~~
underline = __underline__
underline italics = __*underline italics*__
underline bold = __**underline bold**__
underline bold italics = __***underline bold italics***__
Don't want to use markdown? You can slap a backslash in front of your statement, and it'll escape the markdown formatting.  You'll see those asterisks as you'd like! Just keep in mind, it doesn't work in messages with edits or underscores.

2016-06-16

See... everyone uses Markdown now.


  1. Titans rule | Warlocks drool. 

Comments

Top