<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Writing on Stefano Chiodino</title>
    <link>https://stefano.chiodino.uk/tags/writing/</link>
    <description>Recent content in Writing on Stefano Chiodino</description>
    <generator>Hugo -- 0.147.7</generator>
    <language>en</language>
    <lastBuildDate>Tue, 29 Aug 2023 00:00:00 +0000</lastBuildDate>
    <atom:link href="https://stefano.chiodino.uk/tags/writing/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Encrypted synched Obsidian vault journaling on MacOS</title>
      <link>https://stefano.chiodino.uk/posts/2023-08-29-encrypted-synched-obsidian-vault-journaling-macos/</link>
      <pubDate>Tue, 29 Aug 2023 00:00:00 +0000</pubDate>
      <guid>https://stefano.chiodino.uk/posts/2023-08-29-encrypted-synched-obsidian-vault-journaling-macos/</guid>
      <description>&lt;h1 id=&#34;the-boring-prose-bit&#34;&gt;The boring prose bit&lt;/h1&gt;
&lt;p&gt;Journaling has been a useful tool for personal reflection. One thing that I really like is that it&amp;rsquo;s private, which means that I can be open and honest. I don&amp;rsquo;t need to worry to be judged or hurt people&amp;rsquo;s feeling. It&amp;rsquo;s just like thinking, but with rubber-ducking included. It&amp;rsquo;s interesting to go back and read old entries, and I find it it&amp;rsquo;s easier to focus on my thoughts.&lt;/p&gt;</description>
      <content:encoded><![CDATA[<h1 id="the-boring-prose-bit">The boring prose bit</h1>
<p>Journaling has been a useful tool for personal reflection. One thing that I really like is that it&rsquo;s private, which means that I can be open and honest. I don&rsquo;t need to worry to be judged or hurt people&rsquo;s feeling. It&rsquo;s just like thinking, but with rubber-ducking included. It&rsquo;s interesting to go back and read old entries, and I find it it&rsquo;s easier to focus on my thoughts.</p>
<p>So far, I really liked Day One to keep my journal. This is a fantastic free option if you want to journal from one computer. To sync your journal between computers (and more) it requires a premium subscription of $34.99 per year (currently £27.74). This is a very good price for what you get.</p>
<p>However, I was a bit bored, and I wanted to play with <a href="https://obsidian.md/">Obsidian</a> because <a href="https://news.ycombinator.com/">Hacker News</a> absolutely loves Obsidian. I regretted getting advices from Hacker news only 70% of times.</p>
<p>There are various solutions to encrypt notes, add secrets, etc in Obsidian. However, I couldn&rsquo;t find a plugin that ticked all the boxes, so I iterated on an <a href="https://forum.obsidian.md/t/can-i-encrypt-a-vault/33645">Obsidian forum answer</a>.</p>
<h1 id="how-to-encrypt-your-obsidian-vault">How to encrypt your Obsidian vault</h1>
<p>On MacOS, open The Disk Utility app.</p>
<ul>
<li>If you don&rsquo;t already have a vault, in the menu, select <code>File -&gt; New Image -&gt; Blank Image...</code></li>
<li>If you already have a vault, in the menu, select <code>File -&gt; New Image -&gt; Image From Folder...</code>, and use your vault&rsquo;s folder</li>
</ul>
<p>Then, select the strongest encryption option, and a <code>read/write</code> image format. Since you are at it, put it in your iCloud / dropbox / gDrive / etc folder.</p>
<p><img loading="lazy" src="/images/Pastedimage20230830083133.png"></p>
<p>You now have an encrypted file. To mount it you&rsquo;ll be asked for the password, but if you&rsquo;d like you can save it in your keyring so that you won&rsquo;t have to type it every time. This, however, goes against most of the reasons you&rsquo;d be wanting this setup 😉. When mounted, you vault folder will be located in <code>/Volumes/Obsidian Vault</code> or something similar, and easy to reach in finder:</p>
<p><img loading="lazy" src="/images/Pastedimage20230830115637.png"></p>
<h1 id="how-to-sync">How to sync</h1>
<p>Obsidian vaults are folders. They are portable, in the sense that they contain all the settings and plugins related to the vault. This is a great advantage because it makes synching even easier.</p>
<p>Just put your encrypted vault file in a folder synched with any cloud service.</p>
<p>The file will be written when the vault is ejected from the system. This is an important consideration to keep in mind, which I couldn&rsquo;t work around.</p>
<h1 id="refinements">Refinements</h1>
<p>So far we have tickets all the boxes that I wanted, but automating is fun, so here is how to turn a 3-clicks workflow into a 1-click one.</p>
<p>The biggest issues with the setup so far is that the vault needs to be ejected from the system for the file to be synched, and preventing anybody from accessing their raw content without the password.</p>
<h1 id="mounting-journaling-ejecting-synching">Mounting, journaling, ejecting, synching</h1>
<p>Automating mounting the vault before Obsidian is launched is even easier: create a script to mount the vault, then launch Obsidian, then eject the folder.</p>
<div class="highlight"><pre tabindex="0" class="chroma"><code class="language-shell" data-lang="shell"><span class="line"><span class="cl">open --wait-apps /Users/stefanochiodino/Documents/Obsidian<span class="se">\ </span>Vault.dmg <span class="o">&amp;&amp;</span>
</span></span><span class="line"><span class="cl">  open --wait-apps /Applications/Obsidian.app <span class="o">&amp;&amp;</span>
</span></span><span class="line"><span class="cl">  hdiutil detach /Volumes/Obsidian<span class="se">\ </span>Vault
</span></span></code></pre></div><p><code>--wait-apps</code> tells <code>open</code> to wait for that app, which makes it easier to chain commands together.</p>
<p>When you run this, you&rsquo;ll see a terminal window open during this workflow.</p>
<p>Annoyingly, closing the Obsidian window but keeping the app running means that the vault is not ejected. A non ejected vault is a not synched vault either!</p>
<h1 id="a-safer-ejection">A safer ejection</h1>
<p>To help with the issue of Obsidian not shutting down just by closing the window, you could force ejecting the vault when that window is open.</p>
<p><a href="https://obsidian.md/plugins?id=obsidian-shellcommands">Shell commands</a> is an awesome Obsidian plugin that allows to run shell commands, automatically. You can configure it to automatically eject the folder when Obsidian is closed:</p>
<p>Create a new command <code>hdiutil detach -force /Volumes/Obsidian\ Vault</code>.</p>
<p><img loading="lazy" src="/images/Pastedimage20230830120852.png"></p>
<p>Configure the command to execute automatically when Obsidian is closed:</p>
<p><img loading="lazy" src="/images/Pastedimage20230830120940.png"></p>
<h1 id="pro-and-cons">Pro and cons</h1>
<p>Pro:</p>
<ol>
<li>Simple setup</li>
<li>Very low friction to write encrypted synched notes</li>
<li>Leverages Apple&rsquo;s encryption, because the less encryption you do the safer it is</li>
<li>Few and easy to understand commands, so that you know what you are doing and that I&rsquo;m not screwing you over</li>
<li>Free</li>
</ol>
<p>Cons</p>
<ol>
<li>How can I be sure that Apple/Dropbox/Google/etc won&rsquo;t just delete my account an my files? You could setup a symlink to make sure that the files are in another folder as well.</li>
<li>No mobile setup</li>
<li>In this incarnation, MacOS only</li>
<li>The vault syncs only when it&rsquo;s ejected from the system</li>
<li>The lack of CLI commands for Obsidian makes this harder than it could have been ☹️</li>
</ol>
<h1 id="alternatives">Alternatives</h1>
<p><a href="https://obsidian.md/sync">Obsidian Sync</a> offers end-to-end encryption, and supports the Obsidian project. However, it doesn&rsquo;t encrypt the vault at rest. You could still mix and match the approaches: encrypt the vault at rest using the method above, and sync using Obsidian&rsquo;s service.</p>
<p><a href="https://jrnl.sh/">jrnl.sh</a> is a command line journaling tool. It offers very good encryption at rest, and can be synched using any cloud service. Comes with the usual pro and cons of a mostly CLI app.</p>
<p><a href="https://dayoneapp.com/">Day One</a> is a great app for journaling. The premium plan is quite accessible and allows to sync. It even works on a browser (beta), which means that it&rsquo;s platform agnostic. This doesn&rsquo;t solve encrypting at rest tho!</p>
<h1 id="gotchas">Gotchas</h1>
<ol>
<li>I&rsquo;m not an Obsidian expert, so don&rsquo;t just listen to me.</li>
<li>By default, Obsidian will move deleted files to the system trash, where they will be stored unencrypted.</li>
</ol>
]]></content:encoded>
    </item>
    <item>
      <title>Notes on Coursera Business Writing Course</title>
      <link>https://stefano.chiodino.uk/posts/2020-10-22-notes-on-coursera-business-writing-course/</link>
      <pubDate>Thu, 22 Oct 2020 00:00:00 +0000</pubDate>
      <guid>https://stefano.chiodino.uk/posts/2020-10-22-notes-on-coursera-business-writing-course/</guid>
      <description>My notes on a business writing course</description>
      <content:encoded><![CDATA[<ul>
<li>Clarity above all.</li>
<li>Don&rsquo;t waste the reader&rsquo;s time. &ldquo;If I had more time, I would have written a shorter letter&rdquo; - Blaise Pascal.</li>
<li>The look makes a difference. Make your text easier on the eyes. Use bullet points, white space, shorter sentences, margins, boldface, etc .</li>
<li>Be smart: don&rsquo;t try to sound smart. Avoid jargon.</li>
<li>Be the authority: don&rsquo;t use &ldquo;I&rsquo;m thinking&rdquo;, &ldquo;in my opinion&rdquo;, etc.</li>
<li>Scaffold well to write well. Structure you text in 3 phases: say what you want to say, say it, repeat it.</li>
<li>One idea per paragraph</li>
<li>Every paragraph should start with a strong sentence on the paragraph&rsquo;s topic.</li>
<li>Start with your purpose, not the motivation or justification for it.</li>
<li>The text may become too mechanical after revising. Keep your &ldquo;voice&rdquo; in your document by reading it out loud.</li>
<li>If you find duplicate sentences, cut out the negative sounding ones first.</li>
<li>Grammar matters.</li>
<li>Grammar - I vs me: use I if it&rsquo;s a subject</li>
<li>Attribute modifiers like adjectives need to one of the nouns. Make them adjacent.</li>
<li>pronouns are words that take the place of nouns, like I, he, them. They refer to the closest antecedent noun.</li>
<li>Think of the writing from your reader perspective</li>
<li>Cut adjectives and adverbs; qualifiers and amplifiers; “in fact”, “possibly”, “generally”, etc</li>
<li>Cut out generalities like &ldquo;everyone knows&rdquo;, they often include the words: all everybody, everywhere, etc. You may need to rewrite sentences to make them more specific if they include words like: some, somebody, etc.</li>
<li>use an active voice: &ldquo;Bob did X&rdquo;, not &ldquo;X was done by Bob&rdquo;. Passive voice is longer, less clear, and less emphatic. But it&rsquo;s acceptable in scientific papers because it sounds more impartial.</li>
<li>Limit verbs &ldquo;to be&rdquo; and &ldquo;to have&rdquo;. Including forms is, am, are, were, was, will be, have, has, had, have been and more.</li>
</ul>
<p>Ref: <a href="https://www.coursera.org/learn/writing-for-business/">Business Writing course on Coursera</a></p>
]]></content:encoded>
    </item>
  </channel>
</rss>
