cygwinwindows-terminalcygwin-64

How to start cygwin with x11 support in Windows Terminal


I am using Cygwin in Windows Terminal by setting the command line option to D:\cygwin64\Cygwin.bat. It works well but now I need to have X11 support so that I can use X11 forward in ssh command.

I have no idea how to setup this. There are some similar issues but they don't provide the solution I want.


Solution

  • You need to start the XWin Server and then enter in the terminal:

    export DISPLAY=:0.0; export GNUTERM=x11; export GNUPLOT_DRIVER_DIR=/usr/libexec/gnuplot/6.0
    

    should then have access to x11 windows. GNUTERM and GNUPLOT_DRIVER_DIR are for gnuplot, if you need it.