flynn/slugrunner — pull request #10 by bacongobbler (2014-04-23 19:14:40+00:00)
Title: fix(runner): skip sourcing if no file exists

Before, slugrunner would try to source .profile.d/* as a file, which would fail because .profile.d/* is not present. Switching to using `ls` will skip the for loop if no file is present in the directory.

To show the difference between the two commands:

```
$ for file in .profile.d/*; do echo $file; done
.profile.d/*
$ for file in `ls .profile.d`; do echo .profile.d/$file; done
$ touch .profile.d/echo
$ for file in .profile.d/*; do echo $file; done
.profile.d/echo
$ for file in `ls .profile.d`; do echo .profile.d/$file; done
.profile.d/echo
```