lirantal / is-website-vulnerable

finds publicly known security vulnerabilities in a website's frontend JavaScript libraries
Apache License 2.0
1.94k stars 111 forks source link

Gracefully handle missing URL argument #58

Closed itaisteinherz closed 4 years ago

itaisteinherz commented 4 years ago

(image source: https://aquarium.org/sea-otter-holding-facility/)

Description

This PR makes the CLI gracefully handle cases where a URL isn't provided to the CLI by the user, by asking for it while running (using inquirer, since I've used it in the past and know it works well). This fixes #56.

Types of changes

Related Issue

56

How Has This Been Tested?

I locally tested the CLI to make sure this works.

Screenshots (if appropriate):

Screen Shot 2019-12-19 at 23 59 43

Checklist:

itaisteinherz commented 4 years ago

(Last note: I couldn't get the commit hooks to work on my machine, and so the commit messages might be a bit off. Feel free to update the PR title, and I can also update my commit messages in case that's necessary.)

lirantal commented 4 years ago

@itaisteinherz great job and thank you for working on this 🙏✨ Can I ask that we replace inquirer with enquirer? smaller footprint.

itaisteinherz commented 4 years ago

Can I ask that we replace inquirer with enquirer? smaller footprint.

Sure 👌🏻 (Didn't know about it up until now, looks cool)

lirantal commented 4 years ago

@itaisteinherz looks like we're all good. Did you intend to make any other changes here or is it ready to merge?

itaisteinherz commented 4 years ago

@lirantal I think I'm good. After you take a look at 98df7cf646e46863b1a15a9ed227185c12a9d050, we can merge this PR.

lirantal commented 4 years ago

@itaisteinherz thanks, though being honest I don't fancy the async main style and the throwing of errors (did you see my comment about it with regards to stack traces and verbose output?)

lirantal commented 4 years ago

@itaisteinherz let's merge this PR and work out some refactoring in a follow-up.

lirantal commented 4 years ago

@itaisteinherz landed 🎉 thank you for sending this. truly appreciate the effort ❤️

github-actions[bot] commented 4 years ago

:tada: This PR is included in version 1.10.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: