bearblogr
Code Block Examplefrontmatter
Code Block Examplebearblogr is a tool for macOS that converts the popular Bear app into a content management system (CMS) for your static blog.
It allows you to publish and update content from Bear to a Gatsby, Jekyll, Hugo or other statically generated site in a few simple clicks.
If you want to read more about static sites and using Bear for blogging, check out this article.
The following guide will explain how to install, setup, and use bearblogr for first time users.
bearblogr
and frontmatter
code blocks to your note[ SHIFT ] + [ ALT/OPTION ] + [ ⌘ ] + I
(M)arkdown
button to generate a markdown file. Markdown files are stored in ~/bearblogr/
(G)it
button. It will automatically clone/pull your Git repo, create a commit, and push the changes back to your remote.[ SHIFT ] + C
shortcut to copy the latest revision to your local repo and view your rendered version immediately.That’s it!
Please note that bearblogr is currently in beta and has been tested on macOS Catalina v10.15.6 only.
Download links:
Download links:
Once the .dmg
package is downloaded, installation is the same as any other macOS app:
The following prerequisites are necessary if you are planning on publishing content to Git or S3. To make full use of all features, most users should go ahead and install the prerequisites now.
We won’t be going over the step by step details for each service here. Instead, we have included links to resources for detailed guides and explanations on setting them up.
In order to commit and push to Git repositories, you will need to have git
command line tools installed on your system.
In order to push to Git, you will need to have aws
command line tools installed on your system.
bearblogr requires password-less authentication if you are planning on using Git or S3. This is both a security requirement as well as a convenience that makes the publishing workflow much smoother.
If you haven’t done this already, here are a few guides that we have found helpful.
For Git:
For AWS:
We highly recommend testing your Git and AWS configurations by hand first to ensure that they are configured properly before using bearblogr.
During processing, bearblogr makes use of special configuration code blocks embedded within each Bear note. They determine how to process and upload your note’s content when you’re ready to publish them to Git or S3.
bearblogr
and frontmatter
tags mean nothing to syntax highlighters)key: value
format.:
and values are processed directly after the space.”
or single '
quotes even if they have spaces.bearblogr code blocks are parsed individually for each Bear note. This means that you have the flexibility to write and push content to multiple blogs with a single Bear account.
Currently, bearblogr supports 2 specific types of code blocks:
bearblogr
- Configuration for markdown processing, Git, and AWS S3frontmatter
- Contains frontmatter for blog postbearblogr
Code Block Example```bearblogr
md:
fileName: 2020-10-31-Super-Spooky-Halloween-Rocket-Launch
git:
repo: 'git@github.com:elonmusk/spacex-gatsby-blog.git'
repoName: 'spacex-gastby-blog'
repoPath: '/Users/elon/GIT-REPOS'
repoBranch: 'master'
blogPath: 'blog/'
commitMsg: 'Damn, I love bearblogr. Happy Halloween!'
s3:
path: 's3://neoevolutions/blog/posts/'
```
md
Section (required)Configuration relevant to markdown output.
fileName
- Output filename for your processed markdown file
Typically this follows the format/standard for your blog (eg. yyyy-mm-dd-some-URL-friendly-title-with-no-special-characters). Do not include a filename extension (eg *.md
, *.MD
).git
Section (optional)Required if you are pushing to Git from bearblogr.
repo
- URI for your Git remote repositoryrepoName
- Name of your Git repo (without .git)repoPath
- Local path where your repo will be storedrepoBranch
- Branch in your repo where bearblogr commits toblogPath
- Path inside your repo where you store your blog posts (relative to your repo’s root)commitMsg
- Custom commit message. Can be changed for each commit to Git. (PRO VERSION ONLY)s3
Section (optional)Required if you are pushing to an AWS S3 bucket from bearblogr.
path
- URI to your S3 bucket path where markdown files will be storedfrontmatter
Code Block Example```frontmatter
---
title: Super Spooky Halloween Rocket Launch
subtitle: Not for the faint of heart...
path: /blog/2020-10-31-super-spooky-halloween-rocket-launch
date: 2020-10-31T14:18:12.246Z
author: Elon Musk
image: https://spacex.com/logo.png
layout: blog
tags:
- launch
-
- tools
more: custom frontmatter can be added as desired...
---
```
Since frontmatter is custom to each blog and application, the code contained within the frontmatter
code block will be parsed and added at the head of each exported markdown file without any additional modifications.
[TBD]
bearblogr
and frontmatter
code blocks must appear at the top of the note, after the first line.bearblogr
code block should come first, then the frontmatter
code block should come immediately after it.If you’re a fan of using the keyboard to navigate and control your computer, we’ve added a few keyboard shortcuts that allow you to easily control bearblogr without having to use a mouse.
This is especially useful if you are making constant edits and need to generate markdown files frequently.
Below is a list of the currently available keyboard shortcuts for bearblogr.
Shortcut | Action |
---|---|
[ SHIFT ] + M | Generates markdown file from latest version of Bear note |
[ SHIFT ] + G | Copies generated markdown to your local Git repo (performs a pull/clone if necessary), adds a commit message, and pushes to remote (eg. publish your note) |
[ SHIFT ] + S | Upload generated markdown to your AWS S3 bucket. This action will update existing files in the bucket with same name. |
[ SHIFT ] + C | Copy generated markdown to local Git repo only (eg. for previewing your note locally) |
[ CTRL ] + [ SHIFT ] + D | Removes all *.md files in the markdown cache `~/bearblogr` |
V | View last generated markdown file in browser (or your default application used to view *.md files) |
D | Download markdown to `~/Downloads` folder (or your default browser download folder) |
L | Toggle debugging log |
If you like bearblogr, drop me a line at @neooeevo. I want to hear from you!
Don’t forget tosignup for the newsletter for the updates, releases, and access to additional features!
While we do not anticipate any major issues with this software, we are not responsible for any damage or data loss while using bearblogr. Users who download, use, share the above app are subject to our Terms and Conditions outlined here.