Skip to main content

Publish your markdown to Medium, from the CLI

Project description

mdium

publish your markdown to Medium, from the CLI

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.

Finally, 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

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mdium-2.0.0.tar.gz (2.4 kB view hashes)

Uploaded source

Built Distribution

mdium-2.0.0-py3-none-any.whl (3.3 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page