It would be easy to do this for existing notes. You just need a way of programmatically creating the file name for the note, and then you’d just tell the Obsidian URL scheme to open that file.
The following shortcut should be easily modified to do this:
I don’t know exactly what kind of string you need to provide in order to get it to fit with the name of your weekly note, but it should be possible. Share an example weekly note name and I can think about it, if you can’t figure it out yourself.
Getting a shortcut to create the weekly note if it doesn’t already exist it’s also possible, but it would be much more involved. You would need to have someway of detecting my data file already exists, and then if it doesn’t, you would need to invoke some kind of macro — or embed the template for the weekly note directly in Shortcuts — in order to create it properly.
Unfortunately, many of Safari’s iOS Shortcuts actions are not yet available on macOS. There might be some other way of making it work, but it’d be a hacky workaround. Something like “if on macOS, do this, if on iOS, run the shortcut as it currently exists”.
I have several Shortcuts that help me keep my daily note/journal updated throughout the day. The one that gets used the most is my habit tracker.
Because Obsidian is just a text file, I don’t even use Obsidian mobile for this, it just grabs the contents of the text file, modifies it, then resaves it back to the original location. I keep all the habits in the YAML front matter, and present it on the page in a table using Dataview. I also keep a monthly table on a “Dashboard” page that shows my habits over the course of a few weeks.
Here’s what it does:
Get today’s note from my “Dailies” folder (you’ll need to change this if you use it)
Split the text at the “—”
Grab the second item of the split text (this is everything between the "—"s. It’s a few more lines than just my habits, but this way as the habits I’m tracking change, I won’t need to update the Shortcut)
Split that by new lines, this puts each line of the YAML as its own object in Shortcuts.
Choose from list. (By using the actual document to create the list on the fly instead of programming the list in Shortcuts, the options can change as the habits I track change, and I get the added benefit of seeing what I’ve already completed)
Save that as a variable to use later in text replacement
Present another list of emoji icons. I rate each habit on a 1-5 scale using colors.
Replace the text in the file (ex. replace “meditation:” with “meditation: ”)
Hello, I’m wondering if a shortcut can be created to pull a random note from a predefined folder, or otherwise predefined tag?
I’m currently using such a shortcut with Bear. Please see it below. If this shortcut can be modified to perform similarly with Obsidian please let me know how? I would appreciate it!
Obsidian’s core plugin includes a random note plugin, but it doesn’t seem to be able to select a specific folder.
Following is a shortcut that randomly selects a note in a specific folder and opens it in the Obsidian app. (And the shortcut module that is called from it to encodeURIcomponent correctly)
Here’s an idea for a shortcut that I have just built today.
A shortcut/automation that grabs the number of hours I slept and adds it to my daily note.
It’s being run automatically once I turn off my alarm.I plan to extend it to collect additional data, such as how rested I feel, my mood and potentially other data.
Also, I’m new to the community and this is my first post, so Hi Everyone!
Obsidian and the its community are amazing!
And you can do it smarter with the Smart Random Note plugin registered in the community plugins.
With it, you can also randomly display notes with specific tags.
The shortcut that you shared work beautifully. I love it. I have two questions:
1- Can I integrate your shortcut with “Smart Random Note” plug-in? My goal is that I use iOS shortcut app to pull a random note, with a specific tag.
2- can I use shortcut to pull the note content from Obsidian and then get iOS to show it as notification on the screen (without opining up Obsidian App)?
If you just want to randomly display the notes in a specific folder with the Shortcuts app, you can do it with a shortcut RandNoteInSpecFolder.
Since only one line can be displayed for the “Show Notification” action, the result is displayed by the “Show Result” action.
without opining up Obsidian App
The Obsidian app will always open when you use the plugins.
If you process the extraction of notes with a specific tag only with the Shortcuts app, the process will not be completed within the practical time.
You need to think of another way, such as using a Scriptable app.
If you don’t mind launching the Obsidian app in the background, there is a way.
It uses both the shortcuts ShowRandNoteW/Tag and ShowInputMD, and this time the Shortcut Launcher plugin is also used.
The settings of the Shortcut Launcher plugin are as follows :
Command Name:ShowInputMD
Shortcut Name:ShowInputMD
Input Type:Entire Document
It’s called PicSew. It adds an option the “screen recording” feature in control center. You take a “video” of scrolling through any screen on the phone, and the app stitches it together and (optionally) adds a device frame. It’s pretty smart about removing/not duplicating menu and tab bars.
For me, the biggest barrier to note taking has always been dealing with *the process of entering notes, so I made a quartet of shortcuts to make this as painless as possible. I put them in a folder in my Shortcuts app and have a widget in Notification Center that lets me invoke them directly from my phone’s lock screen.
Overview & Links
FastNote Photo immediately lets you take a photo, asks you to type some text, and then saves both files to your vault, named with “FastNote” followed by the date and the appropriate file extensions. The attachment is linked inside the bottom of the note.
FastNote Screenshot is the same as above but takes a screenshot instead of a photo.
FastNote Dictate listens for and transcribes dictation and saves it to your vault.
FastNote Type provides a keyboard for text entry and then saves the text to your vault.
All file names are date-and-time stamped to ensure file names don’t collide.
All these shortcuts (except FastNote Dictate, of course) assume you’ll want to type, though you can use the system Dictation button to speak your note if you choose/change your mind.
Requirements
An iOS/macOS device running Obsidian and synced via iCloud. No other third-party apps are required.
Import Questions
All four shortcuts ask for the location of your Obsidian vault. SnapNote Photo and SnapNote Screenshot also ask for the location of your attachments folder.