redom-cli icon indicating copy to clipboard operation
redom-cli copied to clipboard

Tries to delete current folder when installing to current folder

Open theel0ja opened this issue 7 years ago • 6 comments

~/code/github.com/theel0ja/redom-test   
❯ redom

This utility will initialize a RE:DOM project folder for you.
Just answer these few questions.

Name of the project: (redom-example) redom-test
Relative path where to init: (redom-test) .

Install path: "/Users/eliaso/code/github.com/theel0ja/redom-test"...

Path already exists!
Are you sure you want to replace the existing path?: (n) y
/Users/eliaso/.config/yarn/global/node_modules/redom-cli/bin/redom.js:175
      throw err;
      ^

Error: EINVAL: invalid argument, rmdir '.'

theel0ja avatar Dec 08 '18 09:12 theel0ja

Hmm..not sure how should work then? Clear it instead?

pakastin avatar Dec 08 '18 10:12 pakastin

Well, how can I install ReDOM to current directory if not with .?

theel0ja avatar Dec 08 '18 11:12 theel0ja

npm i redom? 😄

The idea is to be a simple starting point really, not to install RE:DOM to existing project..

pakastin avatar Dec 08 '18 12:12 pakastin

Well, I wanted simple starting point, but to current directory, not add to existing one. create-react-app offers that I think (or I have just moved all files from the created folder to the current one... 🙄 )

theel0ja avatar Dec 08 '18 12:12 theel0ja

Ok yeah, have to study that more then..

Files are here anyway: https://github.com/redom/redom-cli/tree/master/assets

pakastin avatar Dec 08 '18 13:12 pakastin

@theel0ja i might consider making a tool like create-react-app for redom, i will mention you again when its done.

mrwanashraf avatar Sep 29 '19 02:09 mrwanashraf