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

cmder v1.3.10 ignores user_profile #1990

Closed
jrappen opened this issue Dec 19, 2018 · 12 comments
Closed

cmder v1.3.10 ignores user_profile #1990

jrappen opened this issue Dec 19, 2018 · 12 comments

Comments

@jrappen
Copy link
Contributor

jrappen commented Dec 19, 2018

cmder v1.3.10 ignores my .cmder/config/user_profile.cmd file. Strangely, as soon as I change the user_profile.cmd file, conemu looses all colors. user_aliases.cmd works as expected.

I updated from v1.3.6 to v1.3.10. Didn't have the time to check all releases in between.

@daxgames
Copy link
Member

daxgames commented Dec 19, 2018

@jrappen Not a behavior I have seen. What do you mean ignoring? Is it creating a new file or just not running the one you expect?

Cmder 1.3.6 used %cmder_root%\config\user-profile.cmd. Cmder 1.3.10 uses %cmder_root%\config\user_profile.cmd but it should convert the old file name to the new filename.

Add /d /v to your cmder task and start a new session and post the output. You can also run cmder_diag.cmd and post the output.

@jrappen
Copy link
Contributor Author

jrappen commented Dec 20, 2018

  • I am aware of the changed path.
  • See below for output.

🔎 click for details
...>cd vendor

...\vendor>cd bin

...\vendor\bin>cmder_diag.cmd
------------------------------------
dir "..."
------------------------------------
 Datenträger in Laufwerk C: ist Windows

 Verzeichnis von ...

2018-12-03  14:17    <DIR>          .
2018-12-03  14:17    <DIR>          ..
2018-12-03  13:53    <DIR>          bin
2018-11-30  22:20           139.776 Cmder.exe
2018-12-03  13:48    <DIR>          config
2018-11-30  22:20    <DIR>          icons
2018-11-30  22:20             1.069 LICENSE
2018-12-11  15:12    <DIR>          vendor
2018-11-30  22:20                 0 Version 1.3.10.811
               3 Datei(en),        140.845 Bytes
               6 Verzeichnis(se), 127.055.343.616 Bytes frei

------------------------------------
dir "...\vendor"
------------------------------------
 Datenträger in Laufwerk C: ist Windows

 Verzeichnis von ...\vendor

2018-12-11  15:12    <DIR>          .
2018-12-11  15:12    <DIR>          ..
2018-11-30  22:20    <DIR>          bin
2018-12-11  14:11    <DIR>          clink
2018-11-30  22:20    <DIR>          clink-completions
2018-11-30  22:20            12.573 clink.lua
2018-11-30  22:20             4.043 cmder_exinit
2018-12-20  22:20    <DIR>          conemu-maximus5
2018-11-30  22:20            54.990 ConEmu.xml.default
2018-12-11  14:14    <DIR>          git-for-windows
2018-11-30  22:20            15.190 init.bat
2018-11-30  22:20    <DIR>          lib
2017-12-04  08:17    <DIR>          llvm
2018-11-30  22:20             7.803 profile.ps1
2018-11-30  22:20    <DIR>          psmodules
2018-11-30  22:20                49 Readme.md
2018-11-30  22:20               718 sources.json
2018-11-30  22:20               440 user_aliases.cmd.example
               8 Datei(en),         95.806 Bytes
              43 Verzeichnis(se), 127.055.343.616 Bytes frei

------------------------------------
dir /s "...\bin"
------------------------------------
 Datenträger in Laufwerk C: ist Windows

 Verzeichnis von ...\bin

2018-12-03  13:53    <DIR>          .
2018-12-03  13:53    <DIR>          ..
2018-11-30  22:20                84 Readme.md
               1 Datei,                84 Bytes

     Anzahl der angezeigten Dateien:
               1 Datei,                84 Bytes
               2 Verzeichnis(se), 127.055.343.616 Bytes frei

------------------------------------
dir /s "...\config"
------------------------------------
 Datenträger in Laufwerk C: ist Windows

 Verzeichnis von ...\config

2018-12-03  13:48    <DIR>          .
2018-12-03  13:48    <DIR>          ..
2018-12-03  13:48                 0 .history
2018-12-03  13:48    <DIR>          profile.d
2018-11-30  22:20               794 Readme.md
2018-12-03  13:48             4.131 settings
2018-12-20  22:17            55.101 user-ConEmu.xml
2018-12-03  14:25             1.275 user_aliases.cmd
2018-12-17  10:50             1.946 user_profile.cmd
               6 Datei(en),         63.247 Bytes

 Verzeichnis von ...\config\profile.d

2018-12-03  13:48    <DIR>          .
2018-12-03  13:48    <DIR>          ..
               0 Datei(en),              0 Bytes

     Anzahl der angezeigten Dateien:
               6 Datei(en),         63.247 Bytes
               5 Verzeichnis(se), 127.055.343.616 Bytes frei

------------------------------------
set
------------------------------------
aliases=...\config\user_aliases.cmd
ALLUSERSPROFILE=C:\ProgramData
ANSICON=140x1000 (140x37)
ANSICON_DEF=7
APPDATA=...\AppData\Roaming
architecture=64
architecture_bits=64
ccall=call ...\vendor\bin\cexec.cmd
cexec=...\vendor\bin\cexec.cmd
CMDER_ALIASES=1
CMDER_CLINK=1
CMDER_CONFIGURED=1
CMDER_INIT_END=22:20:51,46
CMDER_INIT_START=22:20:48,92
CMDER_ROOT=...
CMDER_SHELL=cmd
CMDER_USER_FLAGS=
CommonProgramFiles=C:\Program Files\Common Files
CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
CommonProgramW6432=C:\Program Files\Common Files
COMPUTERNAME=XXXXXXXX
ComSpec=C:\WINDOWS\system32\cmd.exe
ConEmuANSI=ON
ConEmuAnsiLog=
ConEmuArgs=/Icon "...\icons\cmder.ico" /Title Cmder
ConEmuArgs2=
ConEmuBackHWND=0x000E0538
ConEmuBaseDir=...\vendor\conemu-maximus5\ConEmu
ConEmuBaseDirShort=...\vendor\conemu-maximus5\ConEmu
ConEmuBuild=180626
ConEmuCfgDir=...\vendor\conemu-maximus5
ConEmuConfig=
ConEmuDir=...\vendor\conemu-maximus5
ConEmuDrawHWND=0x000D04A8
ConEmuDrive=C:
ConEmuHooks=Enabled
ConEmuHWND=0x001A0482
ConEmuPalette=<Tomorrow Night Eighties>
ConEmuPID=12664
ConEmuServerPID=8980
ConEmuTask={cmd::Cmder}
ConEmuWorkDir=...
ConEmuWorkDrive=C:
CYGWIN=nodosfilewarning
debug_output=0
DriverData=C:\Windows\System32\Drivers\DriverData
fast_init=0
feFlagName=
GIT_INSTALL_ROOT=...\vendor\git-for-windows
GYP_MSVS_VERSION=2015
HOME=...
HOMEDRIVE=C:
HOMEPATH=\Users\..
LANG=de_DE.UTF-8
lib_base=call "...\vendor\lib\lib_base.cmd"
lib_console=call "...\vendor\lib\lib_console.cmd"
lib_git=call "...\vendor\lib\lib_git.cmd"
lib_path=call "...\vendor\lib\lib_path.cmd"
lib_profile=call "...\vendor\lib\lib_profile.cmd"
LOCALAPPDATA=...\AppData\Local
LOGONSERVER=\\XXXXXXXX
max_depth=1
NUMBER_OF_PROCESSORS=4
OS=Windows_NT
Path=...\bin;...\vendor\bin;...\vendor\conemu-maximus5\ConEmu\Scripts;...\vendor\conemu-maximus5;...\vendor\conemu-maximus5\ConEmu;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:\windows\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\GNU\GnuPG\pub;C:\WINDOWS\System32\OpenSSH\;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:\windows\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\GNU\GnuPG\pub;C:\WINDOWS\System32\OpenSSH\;...\AppData\Local\Microsoft\WindowsApps;...\AppData\Local\Microsoft\WindowsApps;...\vendor\git-for-windows\cmd;...\vendor\git-for-windows\mingw64\bin;...\vendor\git-for-windows\usr\bin;...;...\vendor\DeltaCopy;...\vendor\ffmpeg\bin;...\vendor\imagemagick;...\vendor\llvm\bin;...\vendor\mmd\bin;...\vendor\node;...\vendor\ruby\bin;...\vendor\ruby-devkit\bin;...\vendor\ruby-devkit\mingw\bin;...\vendor\sqlite-tools;...\vendor\tex\MiKTeX\texmfs\install\miktex\bin;...\vendor\tex\SumatraPDF;...\vendor\winpython-3\python-3.6.2.amd64;...\vendor\winpython-3\python-3.6.2.amd64\Scripts;...\vendor\win-flex-bison;...\vendor\wkhtmltopdf\bin
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
PLINK_PROTOCOL=ssh
PROCESSOR_ARCHITECTURE=AMD64
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 78 Stepping 3, GenuineIntel
PROCESSOR_LEVEL=6
PROCESSOR_REVISION=4e03
ProgramData=C:\ProgramData
ProgramFiles=C:\Program Files
ProgramFiles(x86)=C:\Program Files (x86)
ProgramW6432=C:\Program Files
PROMPT=$P$G
PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules
PUBLIC=C:\Users\Public
SESSIONNAME=Console
SVN_SSH=...\\cmder\\vendor\\git-for-windows\\bin\\ssh.exe
SystemDrive=C:
SystemRoot=C:\WINDOWS
TEMP=...\AppData\Local\Temp
TERM=cygwin
time_init=0
TMP=...\AppData\Local\Temp
USERDOMAIN=XXXXXXXX
USERDOMAIN_ROAMINGPROFILE=XXXXXXXX
USERNAME=...
USERPROFILE=...
user_aliases=...\config\user_aliases.cmd
verbose_output=0
VS140COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools\
windir=C:\WINDOWS

------------------------------------
where git
------------------------------------
...\vendor\git-for-windows\cmd\git.exe
...\vendor\git-for-windows\mingw64\bin\git.exe

@daxgames
Copy link
Member

@jrappen what is ... in the output above. Did you modify this output to sanitize it of your %userprofile%? This just looks odd to me.

Did you add /d /v to the conemu task?

@jrappen
Copy link
Contributor Author

jrappen commented Dec 20, 2018

  • yes
  • no, I ran cmder_diag.cmd

@daxgames
Copy link
Member

The output of /d /v would also be helpful.

It looks like cmder.exe is directly in your %userprofile% folder.

The output seems to reflect this but parts of it suggest there is a %userprofile%\cmder folder that contains the cmder distribution?

init.bat expects to find user_profile.cmd in %cmder_root%\config but the output has contradictory info. Maybe a result of your sanitization?

@jrappen
Copy link
Contributor Author

jrappen commented Dec 21, 2018

A result of the sanitization, paths are fine. I'll post the other output later.

@gorbunovav
Copy link

gorbunovav commented Dec 21, 2018

@daxgames I think I am observing the same behavior - I've uncommented line about the ssh-agent and it looks like I am staying inside the standard command prompt environment after the agent start.
If I execute "exit" command I will get into the normal cmder with all colors.

It works ok with the pageant variant and it is enough just to launch the "start-ssh-agent.cmd" to reproduce the issue.

@gorbunovav
Copy link

I think it duplicates #1807

@daxgames
Copy link
Member

@gorbunovav @jrappen - If you both are having the same issue then there are possible workarounds linked in the linked issue. Cmder user profile uses an ssh agent script from Git for Windows so it's not something we can fix.

@jrappen jrappen closed this as completed Dec 21, 2018
@jrappen
Copy link
Contributor Author

jrappen commented Dec 21, 2018

@daxgames maybe it would make sense to add /k exit to the ssh-agent line in /vendor/user_profile.cmd.default?

@daxgames
Copy link
Member

@jrappen - Possible I have not really looked lack of priority/time given there were workarounds. If you have time PRs are always welcome.

@jrappen
Copy link
Contributor Author

jrappen commented Dec 22, 2018

@daxgames will do @gorbunovav thanks again for the input

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants