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

composer.phar create-project erased my hard drive #1683

Closed
krnl opened this issue Mar 11, 2013 · 3 comments
Closed

composer.phar create-project erased my hard drive #1683

krnl opened this issue Mar 11, 2013 · 3 comments
Labels
Milestone

Comments

@krnl
Copy link

krnl commented Mar 11, 2013

I was trying to install project via create-project, but I wanted to install it in current working directory (d:\html\hm), and I wasn't sure about the last part of the command.

I tried various options, and than I ran this command, with forward slash at the end

php composer.phar create-project nette/sandbox /

This inmediately erased my whole d:\ drive. All files and directories are gone.

Full log is here:

D:\html\hm>php composer.phar create-project nette/sandbox /
Installing nette/sandbox (v2.0.10)
  - Installing nette/sandbox (v2.0.10)



  [ErrorException]
  copy(//b79a4304e121eda8c3a65ddc34486ae1.10): failed to open stream: No such file or directory



create-project [-s|--stability="..."] [--prefer-source] [--prefer-dist] [--repository-url="..."] [--dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--keep-vcs] package [directory] [version]

Computer setup:
Windows 7 x64
user account with administrator rights
local installation of composer.phar

@stof
Copy link
Contributor

stof commented Mar 11, 2013

/ is not a way to reference the current folder. . is.

@krnl
Copy link
Author

krnl commented Mar 11, 2013

@stof well it's true, but doesn't change the fact that this needs to be fixed

@Seldaek
Copy link
Member

Seldaek commented Mar 11, 2013

It should abort if the directory is not empty, not sure why it wiped everything, but this is indeed a very serious problem. I'll look into it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants