asok / projectile-rails

Emacs Rails mode based on projectile
258 stars 59 forks source link

Error on "Setting current directory" in project with git submodule #132

Open agraul opened 5 years ago

agraul commented 5 years ago

I can't run many (did not try all, just -model, -controller, -view) of the projectile-rails-find-* commands.

This is the error message I got when I tried it with -controller. Others are similar (app/controllers is replaced by app/models etc.): Setting current directory: No such file or directory, /home/alex/programming/software-o-o/app/controllers/opensuse-theme-chameleon/

Project layout (excerpt):

├── app/
├── bin/
├── config/
├── opensuse-theme-chameleon/ (git submodule)
...
└── lib/

To me it looks like app/controllers/ and opensuse-theme-chameleon/ are joined even though they are unrelated git projects.

I removed opensuse-theme-chameleon/ and then it worked fine.

projectile-rails version: 0.17.0 (package version: 20190110.1008) projectile version: 2.0.0 (package version: 20190126.1117) emacs version: 26.1

milouse commented 4 years ago

This is a projectile bug. See bbatsov/projectile#1369 and bbatsov/projectile#1370

Maybe we should workaround ourselves?