properly detect if rake exists