meza / trance-stack

A production-ready Remix stack built for AWS Lambda. Authentication. Security, Internationalization, Feature Flags, Analytics, Tests, Storybook, Ephemeral and Production CI/CD and more.
https://trance-stack.vsbmeza.com
MIT License
260 stars 15 forks source link

Misleading error message when `lefthook` not installed #679

Open cheruvian opened 10 months ago

cheruvian commented 10 months ago

What happened?

When lefthook is not installed (on OSX), it throws a failed to install dependencies error which is misleading.

We should

  1. Update the README to note that lefthook is a prerequisite
  2. Improve the error message if lefthook is not installed

Current experience:

% npx create-remix@latest --template meza/trance-stack trance-stack
Need to install the following packages:
create-remix@2.5.0
Ok to proceed? (y) 

 remix   v2.5.0 💿 Let's build a better website...
      â—¼  Directory: Using trance-stack as project directory

      â—¼  Template: Using meza/trance-stack...
      ✔  Template copied

   git   Initialize a new git repository?
         No

  deps   Install dependencies with npm?
         Yes

 ██████  Dependencies installing with npm...

      â–²  Oh no! Failed to install dependencies.

What did you expect to happen?

I expected it to say

lefthook is not installed

What version of Remix are you using?

2.5.0

eskot commented 8 months ago

I just ran into the same issue and was able to resolve by making sure the git project was initialized. After running git init manually, I was able to successfully run npm install with no failures from lefthook. Now I need to know why the repo was not initialized when I selected yes during the setup - which is another topic :-)

stale[bot] commented 5 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.