From 14074019d62d98885c4c764401a9e7e1fd129f79 Mon Sep 17 00:00:00 2001 From: Bradley Taunt Date: Mon, 10 Jun 2024 10:12:28 -0400 Subject: Set proper timestamps for header and footer HTML templates, update some post contents --- posts/macos-convert-to-html.md | 45 ++++++++++++++++++------------------------ 1 file changed, 19 insertions(+), 26 deletions(-) (limited to 'posts/macos-convert-to-html.md') diff --git a/posts/macos-convert-to-html.md b/posts/macos-convert-to-html.md index 78cc3d3..3349354 100644 --- a/posts/macos-convert-to-html.md +++ b/posts/macos-convert-to-html.md @@ -2,7 +2,7 @@ 2022-01-28 -Since a few people have reached out and thanked me for my previous post [Batch Converting Images to webp with macOS Automator](/batch-webp-conversion), I thought I would continue to share more of my own custom Automator Quick Actions. Today's post will cover the ability to convert *any* text-based document into pure HTML. +Since a few people have reached out and thanked me for my previous post [Batch Converting Images to webp with macOS Automator](/posts/batch-webp-conversion), I thought I would continue to share more of my own custom Automator Quick Actions. Today's post will cover the ability to convert *any* text-based document into pure HTML. I know - there are over 6 billion conversion apps that do this very same thing. But our way of doing it is *cooler*. Our conversion tool: @@ -48,18 +48,17 @@ Wait for everything to finish and you're done! Next you'll want to open the macOS Automator app and create a new "Quick Action" when given the prompt to do so. -
- Toggle prompt for new automation in macOS Automator -
After opening Automator, select "Quick Action" from the menu (link to hi-res image)
-
+![Toggle prompt for new automation in macOS Automator](/public/images/new-automator.webp) + +*After opening Automator, select "Quick Action" from the menu* Now do the following (reference the image further below to make sure your parameters match): -1. Set "Workflow receives current" to documents in any application +1. Set "Workflow receives current" to **documents** in **any application** 2. In the search bar type in "Run Shell Script" 3. Drag-and-drop the "Run Shell Script" from the left pane into the right pane -4. Set the "Shell" parameter to /bin/bash -5. Set "Pass input" as as arguments +4. Set the "Shell" parameter to **/bin/bash** +5. Set "Pass input" as **as arguments** Once all that is done, simply paste the following in the open text field within the "Run Shell Script" item: @@ -72,10 +71,7 @@ Once all that is done, simply paste the following in the open text field within If you've done everything correctly it should look something like this: -
- Automator quick action details for converting to HTML -
This is what your finished Automator quick action should look like (link to hi-res image)
-
+![Automator quick action details for converting to HTML](/public/images/new-automator-2.webp) Save this new Quick Action (Name is something like "Convert to HTML" to keep things simple). That's it! Amazing, right? @@ -83,28 +79,25 @@ Save this new Quick Action (Name is something like "Convert to HTML" to keep thi Now it is finally time to see our Quick Action is *action*! Navigate to any document file in a Finder window and follow along. -1. First, right-click on the file you wish to convert. ([Figure 1](#fig-1)) +1. First, right-click on the file you wish to convert. See Fig.1) 2. In the pop-up container, scroll down and hover over `Quick Actions`. -3. A secondary pop-out will appear. Look for the action `Convert File to HTML` and click it. ([Figure 2](#fig-2)) +3. A secondary pop-out will appear. Look for the action `Convert File to HTML` and click it. See Fig.2) + +![A markdown file in macOS Finder](/public/images/macos-convert-1.webp) -
- A markdown file in macOS Finder -
Figure 1: Finding and right-clicking on your desired file (link to hi-res image)
-
+*Fig 1: Finding and right-clicking on your desired file* -
- Convert to HTML action selection -
Figure 2: From the "Quick Actions" menu, select "Convert to HTML" (link to hi-res image)
-
+![Convert to HTML action selection](/public/images/macos-convert-2.webp) + +*Fig 2: From the "Quick Actions" menu, select "Convert to HTML"* If everything was set up properly (and depending on the size of the file) you should see your converted HTML file show up right next to your existing document. Time to celebrate! Don't forget - you can also *batch* convert multiple files and multiple file *types* at once. The possibilities are endless! -
- Finder window showing a Markdown file and an HTML file -
Our converted document is now available in HTML. Absolutely glorious. (link to hi-res image)
-
+![Finder window showing a Markdown file and an HTML file](/public/images/macos-convert-3.webp) + +*Our converted document is now available in HTML. Absolutely glorious.* ## No Limits -- cgit v1.2.3-54-g00ecf