I'm currently experiencing a weird behavior in projectile while working on a typical Rails project. Long time projectile user but this is the first time I see it:

projectile-find-implementation-or-test: No matching test file found for project type ‘haskell-stack’

(print major-mode) enh-ruby-mode

current file(app/models/user.rb or spec/models/user_spec.rb)

head -1 app/models/user.rb
# == Schema Information

head -1 spec/models/user_spec.rb
# require 'rails_helper'

What's strange is that I didn't open a single Haskell file for a very long time.

--

Added info:

projectile-project-type is a variable defined in ‘projectile.el’. Its value is nil

1

There are 1 answers

0
Nikita Fedyashev On BEST ANSWER

Turns out what confused projectile was the stack.yaml file in the root of the project.

(projectile-register-project-type 'haskell-stack '("stack.yaml")
                                  :project-file "stack.yaml"
                                  :compile "stack build"
                                  :test "stack build --test"
                                  :test-suffix "Spec")

Source