Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More config #736

Merged
merged 2 commits into from
Dec 4, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion config/Readme.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
## Config

All config files must be in this folder. If there is no option to set this folder directly, it has to be hardlinked.
All config files must be in this folder. If there is no option to set this folder
directly, it has to be hardlinked.

* `aliases`: aliases in cmd; called form vendor\init.bat; autocreated from
`vendor\aliases.example`.
* `*.lua`: clink completitions and prompt filters; called from vendor\cmder.lua after all
other prompt filter and clink completitons are initialized; add your own.
* `user_profile.{sh|bat|ps1}: startup files for bash|cmd|powershell tasks; called from their
respective startup scripts in `vendor\`; autocreated on first start of such a task
* `.history`: the current commandline history; autoupdated on close
* `settings`: settings for readline; overwritten on update
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Someone should review the last two lines (settings and conemu.xml)... This is just my current understanding of this...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See also #427

* `ConEmu.xml`: settings from ConEmu (=the UI of cmder -> Preferences); overwritten on update
10 changes: 10 additions & 0 deletions config/cmder.lua → vendor/cmder.lua
Original file line number Diff line number Diff line change
Expand Up @@ -189,3 +189,13 @@ for _,lua_module in ipairs(clink.find_files(completions_dir..'*.lua')) do
dofile(filename)
end
end

-- now do the same for all lua files in config which do not start with '_'
local user_config_dir = clink.get_env('CMDER_ROOT')..'\\config\\'
for _,lua_module in ipairs(clink.find_files(user_config_dir..'*.lua')) do
-- Skip files that starts with _. This could be useful if some files should be ignored
if not string.match(lua_module, '^_.*') then
local filename = user_config_dir..lua_module
dofile(filename)
end
end
2 changes: 1 addition & 1 deletion vendor/init.bat
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
)

:: Run clink
@"%CMDER_ROOT%\vendor\clink\clink_x%architecture%.exe" inject --quiet --profile "%CMDER_ROOT%\config"
@"%CMDER_ROOT%\vendor\clink\clink_x%architecture%.exe" inject --quiet --profile "%CMDER_ROOT%\vendor"

:: Prepare for git-for-windows

Expand Down