13

As I asked and answered here, I found that running 'sudo lein deps causes some problem that forces me to run 'sudo lein swank', which is annoying. And I was told not to use sudo. I use Mac OS X 10.6.4.

So, I'll try to uninstall and reinstall leiningen.

Uninstalling leiningen

  • Removing ~/.m2 directory is just uninstall, is this correct?

(Re)installing leiningen

I followed the steps explained here.

  1. copy the 'lein' to ~/bin/lein and make it runnable.
  2. Run 'lein self-install', and I see ~/.m2/repository is installed.
  3. download leiningen using 'http://github.com/technomancy/leiningen.git' to ~/bin/leinigen

    • At this stage, I can't run 'lein help', but 'sudo lein help'. What's wrong with this?
  4. As a result, I can't run 'lein deps', but 'sudo lein deps, and the problem becomes recursive one.

Questions

  • Q : How to uninstall perfectly with leiningen?
  • Q : Why using 'sudo' makes lein correctly?
2
  • I think this is off-topic and belongs on ServerFault. Jul 29, 2010 at 14:58
  • this question is about how to use a code generation+compiler+ide it is more suited to stack overflow than serverfault. Jul 29, 2010 at 15:32

1 Answer 1

11

yes removing .m2 and then lein self-install should fix this :)

when you can sudo lein ... it created files in .m2 owned by root so removing these and then recreating them as the proper user (you) should fix it. you could perhaps also just change the user on them back to yourself.

chown username:users ~/.m2/*

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.