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

command/exec: Fill ConsoleSize #3627

Merged
merged 1 commit into from
Jun 27, 2022
Merged

Conversation

vvoland
Copy link
Collaborator

@vvoland vvoland commented May 20, 2022

Depends on:

Relates to:

This makes the exec'd process started with console dimensions matching the users terminal.

- How I did it
Set the exec config ConsoleSize to cli stdout tty size

- How to verify it

# resize terminal from the default size

cid=$(docker run -d ubuntu sleep infinity)

docker exec -it $cid stty size
# check if the printed size is as expected

docker exec -it $cid top -n 1
# check if top UI is rendered at the full terminal size

- Description for the changelog

docker exec -t now sets the console size for the exec'd process immediately when it's created

- A picture of a cute animal (not mandatory but encouraged)

This makes the exec'd process console dimensions immediately match the
users terminal.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
@codecov-commenter
Copy link

codecov-commenter commented Jun 27, 2022

Codecov Report

Merging #3627 (a141f1c) into master (bb5c357) will decrease coverage by 0.01%.
The diff coverage is 46.15%.

@@            Coverage Diff             @@
##           master    #3627      +/-   ##
==========================================
- Coverage   59.01%   59.00%   -0.02%     
==========================================
  Files         289      289              
  Lines       24623    24634      +11     
==========================================
+ Hits        14532    14536       +4     
- Misses       9218     9224       +6     
- Partials      873      874       +1     

Copy link
Member

@thaJeztah thaJeztah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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

Successfully merging this pull request may close these issues.

3 participants