0

I am trying to load package depending on a user's login name
For example:

If a user's login name is "user_foo", I would like to (require 'user_foo). I don't want to hard code the user's login name.

I tried:

(require user_login_name)

I got `wrong type argument: symbolp, "user_foo"
What's the right way to do it?

5
(require (intern user-login-name))

require needs a symbol as its argument, the value of user-log-name is a string, intern takes a string and returns a symbol.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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