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

Support new windows 10 1903 Terminal #2121

Closed
1 of 3 tasks
santagada opened this issue Jul 6, 2019 · 18 comments
Closed
1 of 3 tasks

Support new windows 10 1903 Terminal #2121

santagada opened this issue Jul 6, 2019 · 18 comments

Comments

@santagada
Copy link

Purpose of the issue

  • Bug report (encountered problems/errors)
  • Feature request (request for new functionality)
  • Question

Description of the issue

The new windows terminal https://github.com/microsoft/terminal is much much faster and has a ton of nice features that conemu has. Maybe supporting it, even if just by pointing to a page saying how to run cmder inside it would be cool.

@daxgames
Copy link
Member

daxgames commented Jul 6, 2019

Run %cmder_root%/vendor/init.bat inside the new terminal running a cmd.exe session.

@daxgames daxgames closed this as completed Jul 7, 2019
@ladislavsulc
Copy link

Doesn't work, any other idea, please?

@d3473r
Copy link

d3473r commented Nov 22, 2019

To add cmder as a new terminal add this profile in the json settings

{
    "name": "Cmder",
    "commandline": "cmd.exe /k %cmder_root%/vendor/init.bat",
    "icon" : " %cmder_root%/icons/cmder.ico",
    "hidden": false
},

2019-11-22 23_30_08-Windows PowerShell

Full settings example with cmder set as the default shell

{
    "$schema": "https://aka.ms/terminal-profiles-schema",

    "defaultProfile": "{5b4ef9a8-4506-4ac9-930a-5eb1fd0ebf20}",

    "profiles":
    [
        {
            "guid": "{5b4ef9a8-4506-4ac9-930a-5eb1fd0ebf20}",
            "name": "Cmder",
            "commandline": "cmd.exe /k %cmder_root%/vendor/init.bat",
            "icon" : " %cmder_root%/icons/cmder.ico",
            "hidden": false
        },
        {
            "guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
            "name": "Windows PowerShell",
            "commandline": "powershell.exe",
            "hidden": false
        },
        {
            "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
            "commandline": "cmd.exe",
            "name": "cmd",
            "hidden": false
        },
        {
            "guid": "{2c4de342-38b7-51cf-b940-2309a097f518}",
            "hidden": false,
            "name": "Ubuntu",
            "source": "Windows.Terminal.Wsl"
        }
    ],
    "schemes": [],
    "keybindings": []
}

@ladislavsulc
Copy link

@d3473r Perfect. Thank you! Any idea how to have the same syntax highlighting as in Cmder? Would be much appreciated.

@d3473r
Copy link

d3473r commented Nov 23, 2019

I don't think syntax highlighting is possible within cmd, maybe a cmder developer can answer that.

@shadyalfred
Copy link

Is it possible to start Windows Terminal in the last directory I was working on? Is it a command line option or is it not related to cmder but Windows Terminal itself?

@simondebbarma
Copy link

@d3473r My cmder is not installed in sys32, which is where I think the commandline and icon keys are checking.

How should I modify my config file to account for my file dir structure?

image

@hectormz
Copy link

hectormz commented Apr 8, 2020

@0ww Do you have %cmder_root% environment variable set? If you run echo %cmder_root%, it should return C:\Programming\cmder_mini\. If it doesn't you should set the variable to that path.

@daxgames
Copy link
Member

daxgames commented Apr 8, 2020

Instead of using %cmder_root% you can also just point directly ro [drive]:\[folder-path]\cmder\cmder.exe in whatever path it is in and Cmder will set %cmder_root% for you when it starts.

@simondebbarma
Copy link

simondebbarma commented Apr 8, 2020

Oh nice! Awesome tip @daxgames . It worked! Thanks.

@hectormz , I've set the env variables but it didn't work. I probably had to reboot.

@hectormz
Copy link

hectormz commented Apr 8, 2020

@simonpeterdebbarma I think you have to exit all cmd windows etc to load the new env variables. There may be a simpler fix.

@aliahmadcse
Copy link

I have integrated cmder using the profile below:
{
"guid": "{00000000-0000-0000-ba54-000000000132}",
"name": "Cmder",
"commandline": "cmd.exe /k C:/cmder/vendor/init.bat",
"icon": " C:/cmder/icons/cmder_red.ico",
"hidden": false,
"closeOnExit": true,
"cursorColor": "#FFFFFF",
"cursorShape": "bar",
"historySize": 9001,
"padding": "8, 8, 8, 8",
"snapOnInput": true,
"startingDirectory": "%USERPROFILE%"
}

I Hope, this may help someone.

@santagada
Copy link
Author

I've tried cmder in hyper and fluent terminal, I'm now using it in fluentterminal, conemu performance is really bad when theres a lot of text to print. Will try the new terminal as well.

@shadyalfred
Copy link

My opinion isn't a real solution, but if you use cmder for the Linux commands like: ls, touch, etc... Those commands come with git if you have it installed, you can add the path of these commands to your environment paths, and you'll have ls, touch, grep, etc... working in cmd and even PowerShell. I think PowerShell with the new terminal can be a nice experience, specially with some extensions like oh-my-posh.

@Acid-Crash
Copy link

Acid-Crash commented May 21, 2020

Hi here.
I have some issues with setting up Cmder to work properly.
For some reason Terminal fails to recognize %cmder_root% environment variable despite it is set up correctly.
Cmder is installed for me in c:\Program Files\Cmder
Environment variables are set up per this guide
https://github.com/cmderdev/cmder/wiki/Setting-up-Environment-Variables

Try 1:
"commandline": "cmd.exe /k %cmder_root%/vendor/init.bat",
"%cmder_root%" - is not an internal or external...

Try2:
"commandline": "cmd.exe /k c:/Program Files/Cmder/vendor/init.bat"
It gives error "c:/Program" is not an internal or external...

Try3:
Moved Cmder to the root of C drive
"commandline": "cmd.exe /k c:/Cmder/vendor/init.bat",
Now it works

Still, I would like to set up via proper div (c:/Program Files/Cmder/) or via %cmder_root%
Any hints how this can be acheived?

UPD. Testing by cd %cmder_root% from default cmd or from Cmder gives me the proper folder

@Jackenmen
Copy link

@Acid-Crash that's just how arguments in shell usually work - if you want to use a space in argument (or use environment variable that contains space), you need to use quotes.
In this case, it would be:

"commandline": "cmd.exe /k \"C:\Program Files\Cmder\vendor\init.bat\""

or if you have %cmder_root% environment variable available:

"commandline": "cmd.exe /k \"%cmder_root%\vendor\init.bat\""

@daxgames
Copy link
Member

daxgames commented Jun 7, 2020

@Acid-Crash also we do not recommend putting Cmder in c:\program files just not a good idea for other reasons. See: README.md The recommended place is in you %userprofile%

@Bartunek
Copy link

Setting it as @d3473r suggested in #2121 (comment) works great, but for some reason aliases don't work there. I'm running Cmder with the same command inside VSCode and aliases work there fine. I have my aliases as usual in %cmder_root%/config/user-aliases.cmd

Does anyone have an idea if it's some limitation of the new Windows Terminal or it's necessary to add some more specific configuration? Or am I missing something?

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