Commit graph

37 commits

Author SHA1 Message Date
mqliang
a58bc8d2fe kill TODO
Signed-off-by: mqliang <mqliang.zju@gmail.com>
2015-11-12 16:41:25 +08:00
John Howard
7b3e897b0b Windows: Native ANSI console support
Signed-off-by: John Howard <jhoward@microsoft.com>
2015-10-30 13:44:04 -07:00
Christian Rotzoll
3f417b0769 Remove unused variable, fix #16310
Signed-off-by: Christian Rotzoll <ch.rotzoll@gmail.com>
2015-09-15 22:20:10 +02:00
Vincent Demeester
900dadefee Lint pkg/term/windows package
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2015-09-03 22:25:52 +02:00
Veres Lajos
0f78f158aa typofix - https://github.com/vlajos/misspell_fixer
Signed-off-by: Veres Lajos <vlajos@gmail.com>
2015-08-07 23:25:49 +01:00
Aaron Lehmann
0715aa3a13 Fix golint nit in term_windows.go
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2015-07-27 17:40:49 -07:00
Jessie Frazelle
809a231314 Merge pull request #14838 from Microsoft/10662-ansirewrite
Windows: CLI Improvement (TP3)
2015-07-27 17:30:14 -07:00
Vincent Demeester
9bcb3cba83 Lint on pkg/* packages
- pkg/useragent
- pkg/units
- pkg/ulimit
- pkg/truncindex
- pkg/timeoutconn
- pkg/term
- pkg/tarsum
- pkg/tailfile
- pkg/systemd
- pkg/stringutils
- pkg/stringid
- pkg/streamformatter
- pkg/sockets
- pkg/signal
- pkg/proxy
- pkg/progressreader
- pkg/pools
- pkg/plugins
- pkg/pidfile
- pkg/parsers
- pkg/parsers/filters
- pkg/parsers/kernel
- pkg/parsers/operatingsystem

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2015-07-27 21:26:21 +02:00
John Howard
9a30d8cf9f Windows: CLI Improvement
The Ansi parser and their associated actions have been decoupled. Now
parsing results in call backs to an interface which performs the
appropriate actions depending on the environment.

This improvement provides a functional Vi experience and the vttest no
longer panics.

This PR replaces docker/docker #13224 with the latest console updates.

Signed-off-by: John Howard <jhoward@microsoft.com>
2015-07-21 16:38:44 -07:00
Alexander Morozov
7ff1d0babf Fix windows tag in pkg/term
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-07-01 13:16:16 -07:00
David Mackey
b590208498 trivial: typo cleanup
Signed-off-by: David Mackey <tdmackey@booleanhaiku.com>
2015-04-27 13:35:08 -07:00
Jessie Frazelle
501c2916c4 Merge pull request #12471 from coolljt0725/fix_weird_output_format
Fix weird terminal output format
2015-04-20 17:01:02 -07:00
bin liu
34fbb6c622 fix some typos
Signed-off-by: bin liu <liubin0329@gmail.com>
2015-04-17 08:12:13 +00:00
Lei Jitang
c9f6e6de37 Fix weird terminal output format
Signed-off-by: Lei Jitang <leijitang@huawei.com>
2015-04-17 15:28:12 +08:00
Brendan Dixon
a15746e7cf Turned off Ctrl+C processing by Windows shell
Signed-off-by: Brendan Dixon <brendand@microsoft.com>
2015-04-10 15:43:35 -07:00
Brendan Dixon
06eb6c91a0 Corrected int16 overflow and buffer sizes
Signed-off-by: Brendan Dixon <brendand@microsoft.com>
2015-04-09 09:03:04 -07:00
Ahmet Alp Balkan
cdead8bb8f Swap width/height in GetWinsize and monitorTtySize
Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-04-06 14:31:42 -07:00
Brendan Dixon
52a4467d1d Windows console fixes
Corrected integer size passed to Windows
Corrected DisableEcho / SetRawTerminal to not modify state
Cleaned up and made routines more idiomatic
Corrected raw mode state bits
Removed duplicate IsTerminal
Corrected off-by-one error
Minor idiomatic change

Signed-off-by: Brendan Dixon <brendand@microsoft.com>
2015-04-03 15:02:52 -07:00
Ahmet Alp Balkan
15dcfb4f50 term/winconsole: Identify tty correctly, fix resize problem
This change fixes a bug where stdout/stderr handles are not identified
correctly.

Previously we used to set the window size to fixed size to fit the default
tty size on the host (80x24). Now the attach/exec commands can correctly
get the terminal size from windows.

We still do not `monitorTtySize()` correctly on windows and update the tty
size on the host-side, in order to fix that we'll provide a
platform-specific `monitorTtySize` implementation in the future.

Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-03-26 15:11:28 -07:00
Ahmet Alp Balkan
327e5ef601 Disable ANSI emulation in certain windows shells
This disables recently added ANSI emulation feature in certain Windows
shells (like ConEmu) where ANSI output is emulated by default with builtin
functionality in the shell.

MSYS (mingw) runs in cmd.exe window and it doesn't support emulation.

Cygwin doesn't even pass terminal handles to docker.exe as far as I can
tell, stdin/stdout/stderr handles are behaving like non-TTY. Therefore not
even including that in the check.

Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-03-23 18:38:43 +00:00
Tibor Vass
4cbedb8d54 winconsole: cleanup
Signed-off-by: Tibor Vass <tibor@docker.com>
2015-03-22 15:47:54 -04:00
Sachin Joshi
9cc42dea7c Reduce memory allocation and remove channels
Signed-off-by: Sachin Joshi <sachin_jayant_joshi@hotmail.com>
2015-03-19 18:07:56 -07:00
Sachin Joshi
7fc3c0ba26 Fix panic with vi in busybox
Following bugs are fixed:
1.Handle out of bound cursor movements: vi in busybox sets cursor
to (999,999) expecting it to be set to right, bottom correctly.

2.Correctly determine redirected non-terminal file.

Signed-off-by: Sachin Joshi <sachin_jayant_joshi@hotmail.com>
2015-03-18 13:10:57 -07:00
Sachin Joshi
27c2a55648 Use syscall consts, check for errors,
Also rename func for non-windows specific names.

Signed-off-by: Sachin Joshi <sachin_jayant_joshi@hotmail.com>
2015-03-16 14:04:56 -07:00
Sachin Joshi
c23a02e41a Move windows console specific implementation in sub package
Signed-off-by: Sachin Joshi <sachin_jayant_joshi@hotmail.com>
2015-03-16 14:04:53 -07:00
Sachin Joshi
ce22032e9b ANSI terminal emulation for windows
It is implemented by intercepting and interpreting the output
escape sequence by calling win32 console apis.

In addition the input from win32 console is translated to linux keycodes

Signed-off-by: Sachin Joshi <sachin_jayant_joshi@hotmail.com>
2015-03-16 14:04:49 -07:00
Arnaud Porterie
29e7195aaf Remove subdirectories MAINTAINERS files
Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
2015-03-06 18:21:51 -08:00
Yohei Ueda
c1532556b2 Use termios via CGO only on Linux
Signed-off-by: Yohei Ueda <yohei@jp.ibm.com>
2014-11-25 20:49:01 +09:00
Yohei Ueda
92251ceb7b Use termios via CGO
Signed-off-by: Yohei Ueda <yohei@jp.ibm.com>
2014-11-21 22:12:03 +09:00
John Gossman
2d644f8ab1 Refactor pkg/term package for Windows tty support
Signed-off-by: John Gossman <johngos@microsoft.com>
2014-11-14 18:20:53 -08:00
Victor Vieux
bb2a94eeef update go import path and libcontainer
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com> (github: vieux)
2014-07-24 22:19:50 +00:00
Solomon Hykes
316692081a Guillaume is busy full-time on his new business, and no longer available
as a maintainer.

Best of luck on your e-commerce business Guillaume, and thanks for all
the great contributions!

Docker-DCO-1.1-Signed-off-by: Solomon Hykes <solomon@docker.com> (github: shykes)
2014-06-16 06:22:15 -07:00
Guillaume J. Charmes
87b153606a Use BSD raw mode on darwin. Fixes nano, tmux and others
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume@charmes.net> (github: creack)
2014-03-13 11:11:02 -07:00
Guillaume J. Charmes
02be9306bc Update email + add self to pkg/signal
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume@charmes.net> (github: creack)
2014-03-10 20:26:45 -07:00
Guillaume J. Charmes
10ae745ed8 Update bsd specs
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: creack)
2014-03-10 15:19:08 -07:00
Guillaume J. Charmes
31a1003a84 Add Freebsd client support
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: creack)
2014-02-06 16:40:39 -08:00
Solomon Hykes
93d610afe7 Move utility package 'term' to pkg/term 2013-12-23 23:42:37 +00:00