Cmder#
Environement#
You can set environement variables that are set whenever you work with Cmder.
To set a new environement variable, go to Settings -> Startup -> Environement
.
Alias#
Use the alias feature in Cmder to make life easier.
Print all aliases:
alias
Create an alias:
alias gl=git log --oneline --all --graph --decorate $*
Aliases are stored in %CMDER_ROOT%\config\user_aliases.cmd
. You can edit the file directly.
Then to reload the alias use alias /reload
.
Examples#
Go inside a directory, and run a command in a pipenv
environement:
spl-docs-live = cd /d %SPLDIR%\spl-docs $t pipenv run make livehtml
Common Alias#
;= Jupyter and conda
jn = jupyter notebook
jl = jupyter lab
jkl = jupyter kernelspec list
cel = conda env list
.. = cd ..
... = cd .. & cd ..
.... = cd .. & cd .. & cd ..
..... = cd .. & cd .. & cd .. & cd ..
.: = cd .. & cd .. & cd .. & cd .. & cd .. & cd .. & cd .. & cd .. & cd ..
GUI Macros#
GUI macros are the set of functions allowing to control ConEmu window and its consoles. GuiMacro may be triggered from many places, for example from command line or keypress. (Documentation)
Usefull macros:
To add a new macro, go in Settings -> Keys & Macro
and filter by Macros.
Hotkey |
GUI Macro |
---|---|
Ctrl+N |
|
Shift+Ctrl+N |
|
Create tasks#
For example, for quick access to sphinx docs:
If you have Cmder installed and are using pipenv
to edit sphinx documentation,
you can use the following tasks configuration to quickly open the documentation environement.
-new_console:t:"SPL":d:D:\path\to\the\docs cmd /k "%ConEmuDir%\..\init.bat & pipenv shell"
-new_console:t:"SPL Live":d:D:\spl\spl-docs cmd /k "%ConEmuDir%\..\init.bat & pipenv run make livehtml"
Edit the path to the directory where the documentation is located.