Skip to content
This repository has been archived by the owner on Feb 11, 2019. It is now read-only.

use symfony filesystem->exists instead of 'find' #27

Merged
merged 2 commits into from Mar 25, 2014

Conversation

elexx
Copy link
Contributor

@elexx elexx commented Mar 20, 2014

fixes #25

Feedback is welcome!

$process = $this->getProcess("find ~/ -name \".pearrc\"");
$process->run();
if ($process->getOutput()) {
$fs = $this->getFilesystem();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure the benefits of having define the $fs variable here. You're not reusing and having it in the if won't make the size of the statement go outside of the min-line of PSR2.

Other than that, this is exactly what we were talking about.

@jakerella
Copy link
Member

This PR looks good to me, thanks!

My only comment would be that while it may solve @elexx's issue (#25), we've seen this error when there wasn't actually a "timeout" situation. Let's keep our eyes open for an repeats of this error in case there is another cause.

@elexx
Copy link
Contributor Author

elexx commented Mar 20, 2014

@jakerella Do you have any error messages/logs and maybe the output of "ls -la ~" when that related error occurred? I'd really like to have a look at them.

@jwoodcock
Copy link
Member

@elexx everything we have is in ticket #25. I can say it happens often when trying to run virtPHP on a mac.

@elexx elexx changed the title use symfony filesystem->exists instead of 'file' use symfony filesystem->exists instead of 'find' Mar 21, 2014
@elexx
Copy link
Contributor Author

elexx commented Mar 21, 2014

I've tried but was not able to reproduce an exception. Mainly I modified the permissions of .pearrc and created a new environment using the code from this pull request, which printed the warning every time (because .pearrc exists) but created the environment successfully.
I'm using Mac OS X 10.9.2, and PHP 5.5.10 (build using Homebrew)

If you come across that other exception, feel free to @mention me and I'll take at look at it.

ramsey added a commit that referenced this pull request Mar 25, 2014
use symfony filesystem->exists instead of 'find'
@ramsey ramsey merged commit 71c74e8 into virtphp:master Mar 25, 2014
@elexx elexx deleted the find-timeout-fix branch March 25, 2014 21:02
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

create command fails - timeout
4 participants