@@ -2,12 +2,12 @@ local util = require("forester.util")
22local Forester = require (" forester.bindings" )
33local Job = require (" plenary.job" )
44local pickers = require (" forester.pickers" )
5- local Config = require (" forester.config" )
5+ local config = require (" forester.config" )
66local M = {}
77
88M .commands = {
99 config = function ()
10- Config . switch_config ()
10+ config . switch ()
1111 end ,
1212
1313 build = function ()
@@ -31,7 +31,7 @@ M.commands = {
3131 end ,
3232
3333 new_random = function ()
34- local prefixes = Config .all_prefixes ()
34+ local prefixes = config .all_prefixes ()
3535 vim .ui .select (prefixes , { -- TODO: Don't select when #all_prefixes == 1
3636 format_item = function (item )
3737 return item
@@ -43,7 +43,7 @@ M.commands = {
4343 end
4444 else
4545 do
46- local path = Config .dir_of_latest_tree_of_prefix (choice )
46+ local path = config .dir_of_latest_tree_of_prefix (choice )
4747 local new_tree = Forester .new_random (choice , path , vim .g .forester_current_config )[1 ]
4848 vim .cmd (" edit " .. new_tree )
4949 end
@@ -52,7 +52,7 @@ M.commands = {
5252 end ,
5353
5454 new = function ()
55- local prefixes = Config .all_prefixes ()
55+ local prefixes = config .all_prefixes ()
5656 vim .ui .select (prefixes , { -- TODO: Don't select when #all_prefixes == 1
5757 format_item = function (item )
5858 return item
@@ -64,7 +64,7 @@ M.commands = {
6464 end
6565 else
6666 do
67- local path = Config .dir_of_latest_tree_of_prefix (choice )
67+ local path = config .dir_of_latest_tree_of_prefix (choice )
6868 local new_tree = Forester .new (choice , path , vim .g .forester_current_config )[1 ]
6969 vim .cmd (" edit " .. new_tree )
7070 end
@@ -73,7 +73,7 @@ M.commands = {
7373 end ,
7474
7575 transclude_new = function ()
76- local prefixes = Config .all_prefixes ()
76+ local prefixes = config .all_prefixes ()
7777 vim .ui .select (prefixes , { -- TODO: Don't select when #all_prefixes == 1
7878 format_item = function (item )
7979 return item
@@ -85,7 +85,7 @@ M.commands = {
8585 end
8686 else
8787 do
88- local path = Config .dir_of_latest_tree_of_prefix (choice )
88+ local path = config .dir_of_latest_tree_of_prefix (choice )
8989 local new_tree = Forester .new (choice , path , vim .g .forester_current_config )[1 ]
9090 local addr = util .filename (new_tree ):match (" (.+)%..+$" )
9191 local content = { " \\ transclude{" .. addr .. " }" }
@@ -96,7 +96,7 @@ M.commands = {
9696 end ,
9797
9898 link_new = function ()
99- local prefixes = Config .all_prefixes ()
99+ local prefixes = config .all_prefixes ()
100100 vim .ui .select (prefixes , {
101101 format_item = function (item )
102102 return item
@@ -108,7 +108,7 @@ M.commands = {
108108 end
109109 else
110110 do
111- local path = Config .dir_of_latest_tree_of_prefix (choice )
111+ local path = config .dir_of_latest_tree_of_prefix (choice )
112112 local new_tree = Forester .new (choice , path )[1 ]
113113 local addr = util .filename (new_tree ):match (" (.+)%..+$" )
114114 local content = { " [](" .. addr .. " )" } -- NOTE: We should improve the workflow with snippets or something similar
0 commit comments