Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added emoji conversion and louder error message #1

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Changes
  • Loading branch information
akash-joshi committed Mar 6, 2019

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
commit 163e626f708275bf058edfd906fbf1735aed0947
File renamed without changes.
8 changes: 4 additions & 4 deletions app/index.js
Original file line number Diff line number Diff line change
@@ -9,11 +9,11 @@ const { id, token } = require('./config');
const cli = meow(
`
Usage
$ npx @pavanjadhaw/mdm init
$ npx @pavanjadhaw/mdm publish <myAwesomePost.md> …
$ npx mdium init
$ npx mdium publish <myAwesomePost.md> …

Examples
$ npx @pavanjadhaw/mdm publish myAwesomePost.md
$ npx mdium publish myAwesomePost.md
`,
{
flags: {
@@ -38,7 +38,7 @@ const input = cli.input[0];
} else {
console.error(`Specify markdown file to publish

Use '$ npx @pavanjadhaw/mdm -h' for help`);
Use '$ npx mdium -h' for help`);
process.exit(1);
}
})();
4 changes: 2 additions & 2 deletions app/utils/post.js
Original file line number Diff line number Diff line change
@@ -23,9 +23,9 @@ const post = async (id, token, markdownFile) => {
spinner.fail(`Medium integration token or authorID missing.

Have you added authorID gotten from
$ npx @pavanjadhaw/mdm init
$ npx mdium init

Use '$ npx @pavanjadhaw/mdm -h' for help`);
Use '$ npx mdium -h' for help`);
process.exit(1);
}

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"name": "@pavanjadhaw/mdm",
"name": "mdium",
"version": "0.0.4",
"description": "publish your markdown to Medium, from the CLI",
"author": "Pavan Jadhaw <@pavanjadhaw>",
"main": "cli.js",
"bin": {
"mdm": "app/bin/mdm"
"mdium": "app/bin/mdium"
},
"engines": {
"node": ">=8"
4 changes: 2 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
@@ -39,7 +39,7 @@ export MEDIUM_TOKEN='token here'

After adding integration token you can easily get your unique author id by running

`npx @pavanjadhaw/mdm init`
`npx mdium init`

Then export your unique author id as follows

@@ -75,7 +75,7 @@ Medium will then CDN it and you can delete it from there if you want to.
When you’re ready to publish, run

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