Skip to content

Commit

Permalink
Merge pull request #84 from tropf/resize-iff-possible
Browse files Browse the repository at this point in the history
shell config: only resize if on tty
  • Loading branch information
Mic92 authored Oct 7, 2024
2 parents 93e314c + 6543d38 commit 9373ca9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions share/modules/nixos-shell-config.nix
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,8 @@ in {
path = builtins.getEnv "PATH";
in
''
# fix terminal size
eval "$(resize)"
# if terminal with stdout, fix terminal size
if [ -t 1 ]; then eval "$(resize)"; fi
${lib.optionalString (pwd != "") "cd '${pwd}' 2>/dev/null"}
${lib.optionalString (term != "") "export TERM='${term}'"}
Expand Down

0 comments on commit 9373ca9

Please sign in to comment.