Coder Social home page Coder Social logo

journal-down's Introduction

journal-down

Journal in Markdown, using MacDown, backed up to your iCloud.

About:

Lately I've been finding most of my productive writing has been occurring in Markdown. Specifically, I enjoy using MacDown.

To jumpstart more habitual writing, I wanted dead-simple, 0-dependency, Markdown journaling.

  1. From desire to write, to actually writing, as quickly as possible.
  2. Automatic backups to iCloud storage, so I don't have to configure or worry about anything.

Upon searching around, most of the stuff in the simple Markdown journal category came with a lot of extra fluff, required Dropbox, or had a host of dependencies.

This is JournalDown.

How it Works:

JournalDown is a BASH script that manages creating, timestamp-ing, and opening your journal with a cursor in a convenient location, ready to go.

  1. When you run journal-down for the first time it will create a file for you in your iCloud storage like this: /JournalDown/2017/09/2017-09-10.md
  2. JournalDown will add a header to the file with the current date, and day of the week like: # September 10th, 2017 - Monday
  3. Additionally, JournalDown will create a subheading with the current time like: ## 08:44 PM
  4. MacDown will open with the current file and your cursor on a new line ready to type.
  5. Simply โŒ˜-Q out of MacDown when you're finished.
  6. Come back and start writing again by running journal-down and MacDown will open today's journal, add newlines, create a timestamp subheading, and your cursor will be ready to write.

Simple, easy, Markdown journaling.

That is JournalDown.

Requirements

Installation

Be sure you've installed MacDown.

Copy the journal-down file to an accessible location like your home directory.

Make sure the file is executable with: chmod +x journal-down.

Run journal-down to start journaling like this:

./journal-down

Help

For help using journal-down you can use the -h flag like:

~/journal-down -h

This is JournalDown.

Requires:
    MacDown - The open source Markdown editor for macOS.

    https://macdown.uranusjr.com

    ...or with Homebrew Cask: brew cask install macdown

    Default iCloud Storage configuration.

Usage:
    journal-down                      Open journal file for today with a new timestamp.
    journal-down -h                   Display this help message.
    journal-down -o                   Open journal for today.
    journal-down -r <YYYY-MM-DD>      Open a journal for a given valid date like: 2017-09-10.

Development:

This was a pretty fun project that I have a feeling I'll be re-visiting quite a bit. Originally, I wrote this as a PHP script since that's the language I'm most comfortable in.

While the PHP script did the job, it had two problems:

  1. PHP was a dependency. I wanted something that was dead easy to get running on a Mac with MacDown installed.
  2. It was verbose.

I knew that BASH would be a better choice from the get-go, so I went ahead and decided to dust off the ol' BASH-hacking skills. Unfortunately, I couldn't find them anywhere in the noggin so I checked up on some of the current best practices, and leaned on a few people in #bash on Freenode to come up with what we've got here.

There's probably some ways I could improve things, so please feel free to open some issues or throw some pull requests in there.

License:

Copyright (c) 2017 David Drake

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Author:

David Drake

@randomdrake | https://randomdrake.com | LinkedIn

journal-down's People

Contributors

randomdrake avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.