Skip to content
This repository has been archived by the owner on Jun 7, 2021. It is now read-only.
/ mdium Public archive

📄 publish your markdown to Medium, from the CLI

License

Notifications You must be signed in to change notification settings

icyphox/mdium

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

publish your markdown to Medium, from the CLI

Update: Looks like you can get an integration token by emailing customer support?

Medium post I wrote on a whim.

Installation

$ pip install mdium

Usage

Initializing

First off, set up mdium with your Medium integration token. You’ll have to generate one from the settings page.

$ mdium init <integration-token>

This will create a file at ~/.mdium, containing your integration token and author ID.

Publishing

For publishing, your markdown doc must have the following frontmatter:

---
title: My Awesome Post
tags: ['some', 'tags', 'here']
status: draft
---

## markdown here
...

Note that the status field can be either draft or public. I recommend that you publish them as drafts and fine tune using Medium’s editor.

If your post contains images, host them somewhere public and then include them in your document like so:

![cat](https://catpics.com/some_cat.png)

Medium will then CDN it and you can delete it from there if you want to.

When you’re ready to publish, run

$ mdium publish path/to/markdown.md
Done! Your post has been published at https://medium.com/@gaben/76272e9d241c

It’s that simple.

License

MIT © Anirudh Oppiliappan

About

📄 publish your markdown to Medium, from the CLI

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages