Re: Lua Rocks

From: mitchell <mforal.n....at.gmail.com>
Date: Mon, 14 Jun 2010 07:43:15 -0700 (PDT)

Robert,

On Jun 14, 10:41 am, Robert <ro....at.web.de> wrote:
> >> and for common.add would like to add key commands by putting them in
> >> the user key_commands.lua this will not work because key_commands.lua
> >> is loaded before the requiring of common.add so the instructions would
> >> read something like:
> >> "Put every line with require from textadept/init.lua in your user init.lua,
> >> require common.add before textadept.keys, add these key commands to
> >> your key_commands.lua"
>
> > An easier solution would be to extend the code above to:
>
> > if not lfs.attributes(_USERHOME) then
> >   lfs.mkdir(_USERHOME)
> >   local f = io.open(_USERHOME..'/init.lua', 'w')
> >   if f then
> >     f.write("-- require other modules here\n")
> >     f:write("require 'textadept' -- should be required last", "\n")
> >     f:close()
> >   end
> >  end
>
> Correct me if I'm wrong, but I think you can't overwrite the default
> key commands like this. (Which I do use.)

I was operating under the assumption you use ~/.textadept/keys.lua to
define your key commands.

Mitchell

>
Received on Mon 14 Jun 2010 - 10:43:15 EDT

This archive was generated by hypermail 2.2.0 : Thu 08 Mar 2012 - 11:45:58 EST