On a browser like Firefox, I can go to the bookmarks menu and select multiple bookmarks with the shift key, then press CMD C to copy them, but doesn't work on macOS. I wonder if there's a more efficient way to do so.
This doesn’t work in macOS 12 Monterey. When you click on a bookmark, it automatically opens, rather than being simply selected.Bookmarks > Edit Bookmarks (⌥⌘B), press ⌘. select multiple bookmarks, ⌘+C
Ah, thanks for that. That was the problem—I was accessing the bookmarks from the sidebar (and the bookmarks are non-selectable there), and not from the Edit Bookmarks menu. It does indeed work on macOS 12.4, Safari 15.5 as you say. Hopefully the OP will get that as well.Sorry, I should have said press and hold ⌘. Demo in Monterey 12.4 (21F79) Safari 15.5 (17613.2.7.1.8)
View attachment 2009986
It inserts a link (as e.g. shown in #5). I guess thats the default.I created a txt file in textedit and tried pasting multiple bookmarks into it from the Edit Bookmarks menu, and it only pasted in the titles.
Actually, as I have TextEdit set to always use plain text, that was the first thing I tried and it worked.Have u tried this yourself? I created a txt file in textedit and tried pasting multiple bookmarks into it from the Edit Bookmarks menu, and it only pasted in the titles.
Yes, I’ve seen the same behavior in Monterey, as explained above.Here's a video where I paste the URLs in both rich text and plain txt, I'm on Monterey.
defaults read ~/Library/Safari/Bookmarks.plist >> ~/Desktop/Bookmarks.txt
URIDictionary = {
title = "MacRumors Forums";
};
URLString = "https://forums.macrumors.com/categories/macos.182/";
WebBookmarkType = WebBookmarkTypeLeaf;
use AppleScript version "2.4" -- Yosemite (10.10) or later
use framework "Foundation"
use framework "AppKit"
use scripting additions
-- classes, constants, and enums used
property NSPasteboard : a reference to current application's NSPasteboard
set supDataTypes to NSPasteboard's generalPasteboard()'s types()
if supDataTypes's containsObject:"WebURLsWithTitlesPboardType" then
set pbArray to NSPasteboard's generalPasteboard()'s propertyListForType:"WebURLsWithTitlesPboardType"
set URLarray to pbArray's objectAtIndex:0
end if
if URLarray is not {} then
set ASTID to text item delimiters
set text item delimiters to linefeed --"\n"
set the clipboard to (URLarray as list) as string
set text item delimiters to ASTID
end if
Thank you for the script, it’s working in Monterey 12.4 (21F79).Info : Tested on Mojave
You're welcome. Thank you for testing on Monterey 12.4 (21F79).Thank you for the script, it’s working in Monterey 12.4 (21F79).
@bogdanw I just looked back at this and I wonder, how did you get that clipboard window at 0:27?Actually, as I have TextEdit set to always use plain text, that was the first thing I tried and it worked.
Monterey seems to have a problem with the clipboard. One link is copied correctly, but multiple links are pasted as text, although the last URL shows up in Finder – Edit – Show Clipboard. And AppleScript shows….
View attachment 2010728
Finder - Edit - Show ClipboardI just looked back at this and I wonder, how did you get that clipboard window at 0:27?