Giter Site home page Giter Site logo

medium-cli's People

Contributors

bryant1410 avatar churchs19 avatar djadmin avatar greg-js avatar pdehaan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

medium-cli's Issues

Error using "tag" option

Error using "tag" option
~ ❯❯❯ sw_vers
ProductName: Mac OS X
ProductVersion: 10.12.3
BuildVersion: 16D32

NPM version:
~ ❯❯❯ npm -v ⏎
4.4.0

~ ❯❯❯ medium tag javascript
/usr/local/lib/node_modules/mediumcli/lib/post.js:71
for (var i = 0, len = Math.min(count, items.length); i < len; i++) {
^

TypeError: Cannot read property 'length' of undefined
at processContent (/usr/local/lib/node_modules/mediumcli/lib/post.js:71:45)
at /usr/local/lib/node_modules/mediumcli/lib/post.js:128:15
at Request._callback (/usr/local/lib/node_modules/mediumcli/lib/post.js:29:4)
at Request.self.callback (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:186:22)
at emitTwo (events.js:106:13)
at Request.emit (events.js:191:7)
at Request. (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:1081:10)
at emitOne (events.js:96:13)
at Request.emit (events.js:188:7)
at IncomingMessage. (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:1001:12)
at IncomingMessage.g (events.js:292:16)
at emitNone (events.js:91:20)
at IncomingMessage.emit (events.js:185:7)
at endReadableNT (_stream_readable.js:974:12)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)

npm version is not latest

Hi ;-)

I was just writing a quick blog post about your nice project and I noticed you forgot to push v1.3.2 to npm. At least I think so, as I'm unable to fetch the latest version from the npm registry and it shows the last version there is v1.3.1

Search related error using the tag option

I used the command medium tag automation and returned the following error within the output:

`/usr/local/lib/node_modules/mediumcli/lib/post.js:71
for (var i = 0, len = Math.min(count, items.length); i < len; i++) {
^

TypeError: Cannot read property 'length' of undefined
at processContent (/usr/local/lib/node_modules/mediumcli/lib/post.js:71:45)
at /usr/local/lib/node_modules/mediumcli/lib/post.js:128:15
at Request._callback (/usr/local/lib/node_modules/mediumcli/lib/post.js:29:4)
at Request.self.callback (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:188:22)
at emitTwo (events.js:106:13)
at Request.emit (events.js:191:7)
at Request. (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:1171:10)
at emitOne (events.js:96:13)
at Request.emit (events.js:188:7)
at IncomingMessage. (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:1091:12)
at IncomingMessage.g (events.js:291:16)
at emitNone (events.js:91:20)
at IncomingMessage.emit (events.js:185:7)
at endReadableNT (_stream_readable.js:974:12)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)`

Gets: The `punycode` module is deprecated message on READ command

medium read https://python.plainenglish.io/from-googles-coding-desks-to-yours-10-python-secrets-for-success-792dc03d765e
(node:91710) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead.
(Use node --trace-deprecation ... to show where the warning was created)
Unhandled rejection TypeError: Cannot read properties of undefined (reading 'call')
at new StringStream (/opt/homebrew/lib/node_modules/mediumcli/node_modules/string-stream/index.js:5:17)
at printArticle (/opt/homebrew/lib/node_modules/mediumcli/lib/reader.js:37:19)
at /opt/homebrew/lib/node_modules/mediumcli/lib/reader.js:62:47
at tryCatcher (/opt/homebrew/lib/node_modules/mediumcli/node_modules/bluebird/js/main/util.js:26:23)
at Promise._settlePromiseFromHandler (/opt/homebrew/lib/node_modules/mediumcli/node_modules/bluebird/js/main/promise.js:510:31)
at Promise._settlePromiseAt (/opt/homebrew/lib/node_modules/mediumcli/node_modules/bluebird/js/main/promise.js:584:18)
at Promise._settlePromises (/opt/homebrew/lib/node_modules/mediumcli/node_modules/bluebird/js/main/promise.js:700:14)
at Async._drainQueue (/opt/homebrew/lib/node_modules/mediumcli/node_modules/bluebird/js/main/async.js:123:16)
at Async._drainQueues (/opt/homebrew/lib/node_modules/mediumcli/node_modules/bluebird/js/main/async.js:133:10)
at Async.drainQueues [as _onImmediate] (/opt/homebrew/lib/node_modules/mediumcli/node_modules/bluebird/js/main/async.js:15:14)
at process.processImmediate (node:internal/timers:478:21)

Make `open` an option

Right now, medium open <url> is only useful if the user already knows the url, so they'd have to google for it first.

Maybe it works better as an option instead:

medium top --open
medium tag node -o
# whatever article the user selects becomes the url for the `open` function

Doesn't work

undefined:1
<!DOCTYPE html><html xmlns:cc="http://creativecommons.org/ns#"><head prefix="og: http://ogp.me/ns# fb: http://ogp.me/ns/fb# medium-com: http://ogp.me/ns/fb/medium-com#"><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=contain"><title>Popular on Medium – Medium</title><link rel="canonical" href="https://medium.com/topic/popular"><link id="feedLink" rel="alternate" type="application/rss+xml" title="RSS" href="https://medium.com/feed/topic/popular"><meta name="title" content="Popular on Medium – Medium"><meta name="referrer" content="unsafe-url"><meta name="description" content="Popular on Medium on Medium: What’s trending on Medium right now."><meta name="theme-color" content="#000000"><meta property="og:title" content="Popular on Medium – Medium"><meta property="og:url" content="https://medium.com/topic/popular"><meta property="og:image" content="https://cdn-images-1.medium.com/max/1200/1*

SyntaxError: Unexpected token < in JSON at position 0
    at JSON.parse (<anonymous>)
    at Request._callback (/usr/local/lib/node_modules/mediumcli/lib/post.js:28:20)
    at Request.self.callback (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:186:22)
    at Request.emit (events.js:180:13)
    at Request.<anonymous> (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:1163:10)
    at Request.emit (events.js:180:13)
    at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/mediumcli/node_modules/request/request.js:1085:12)
    at Object.onceWrapper (events.js:272:13)
    at IncomingMessage.emit (events.js:185:15)
    at endReadableNT (_stream_readable.js:1106:12)
    at process._tickCallback (internal/process/next_tick.js:114:19)

Filter by 'Tag'

On Medium you can search by tags: 'https://medium.com/tag/startups'

Create an option to search by tags. example usage: medium --tag (-t) startups

Or change medium top and medium open to --top || -t --open || -o -b --browser and then allow search of tags like so: medium startups medium productivity

Definitely open to feedback on how this should work or how you would like it to work.

Character Encoding Error

Window 10
Powershell

Showing wrongly single quotes and double quotes, please have a look below image for reference

medium_cli

medium top - listing everything in markdown

Running medium-cli on a RaspberryPI 3, latest Raspbian, through a vintage vt100 terminal. Running 'medium top' displays everything in pure html. Is it possible to have the titles translated/rendered as plain text?

Using latest nodejs 15 and npm 7.7

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.