Ticket #3345 (new defect) — at Initial Version

Opened 10 years ago

Last modified 2 weeks ago

Subshell not working in GNU screen

Reported by: michalzuber Owned by:
Priority: major Milestone:
Component: mc-core Version: 4.8.13
Keywords: subshell Cc: egmont@…
Blocked By: Blocking:
Branch state: no branch Votes for changeset:

Description

Tried on Arch LInux and OSX, but subshell doesn't work if in GNU screen

Screencast: https://www.youtube.com/watch?v=hMVAVZCj8lI
Arch bug report: https://bugs.archlinux.org/task/42873

$ env
TERM_PROGRAM=iTerm.app
TERM=xterm-256color
SHELL=/bin/bash
HISTSIZE=5000
CLICOLOR=1
TMPDIR=/var/folders/xn/2cw7yp3573z4jr69frj4_b700000gn/T/
Apple_PubSub_Socket_Render=/tmp/launch-mPjxcw/Render
HISTFILESIZE=5000
USER=mike
COMMAND_MODE=unix2003
SSH_AUTH_SOCK=/tmp/launch-I9rIWN/Listeners
Apple_Ubiquity_Message=/tmp/launch-Vxo4Zm/Apple_Ubiquity_Message
CF_USER_TEXT_ENCODING=0x1F5:0:0
PAGER=less
LSCOLORS=GxFxCxDxBxegedabagaced?
PATH=/usr/local/mysql/bin:/opt/phpunit/bin:/opt/local/bin:~/bin:/opt/newsbeuter/bin:/opt/local/sbin:/opt/elasticsearch/bin:/opt/links/bin:~/Downloads/android/sdk/platform-tools:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin
LOCALE=UTF-8
PWD=/Users/mike
DBUS_LAUNCHD_SESSION_BUS_SOCKET=/tmp/launch-riF24S/unix_domain_listener
EDITOR=vim
LANG=en_US.UTF-8
ITERM_PROFILE=Default
PS1=\[\033k\033
\]\u@\h:\w\$
HISTIGNORE=&:ls:[bf]g:exit:config:netrc:clear
HISTCONTROL=ignoreboth
SHLVL=1
HOME=/Users/mike
COLORFGBG=7;0
ITERM_SESSION_ID=w0t0p0
LESS=-i-P%f (%i/%m) Line %lt/%L
LOGNAME=mike
VISUAL=vim
LC_CTYPE=en_US.UTF-8
SECURITYSESSIONID=186a5
_=/usr/bin/env

$ cat .bashrc
#
# ~/.bashrc
#
# http://stefaanlippens.net/my_bashrc_aliases_profile_and_other_stuff

# If not running interactively, don't do anything
# $- != *i* ? && return

# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then

test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)"
eval "$(dircolors -b)"

fi

# Set terminal colors
# http://it.toolbox.com/blogs/lim/how-to-fix-colors-on-mac-osx-terminal-37214
alias ls='ls --color=auto -Fh'
if [ "$(uname)" == "Darwin" ]; then

export CLICOLOR=1
export LSCOLORS=GxFxCxDxBxegedabagaced?
alias ls='ls -GFh'

fi

if [ "$(uname)" == "Linux" ]; then

alias pbcopy='xsel --clipboard --input'
alias pbpaste='xsel --clipboard --output'

fi

export PS1='\u@\h:\w\$ '

export LANG="en_US.UTF-8"
export LOCALE="UTF-8"
export LC_CTYPE="en_US.UTF-8"

export HISTSIZE=5000
export HISTFILESIZE=5000
export HISTIGNORE="&:ls:[bf]g:exit:config:netrc:clear"
export HISTCONTROL=ignoreboth

# append to the history file, don't overwrite it
shopt -s histappend
shopt -s cmdhist
shopt -s cdspell
# Make bash check its window size after a process completes
shopt -s checkwinsize

if [ -f /opt/local/etc/bash_completion ]; then

source /opt/local/etc/bash_completion

fi

[ -r /usr/share/bash-completion/bash_completion ] && . /usr/share/bash-completion/bash_completion

[ -r /usr/share/git/completion/git-prompt.sh ] && . /usr/share/git/completion/git-prompt.sh

# http://hints.macworld.com/article.php?story=20031015173932306
PROMPT_COMMAND='echo -ne "\033]0;${HOSTNAME%%.*}: ${PWD/#$HOME/~}\007"'
case "$TERM" in

screen*)

# https://stackoverflow.com/a/2069095
export PS1='\[\033k\033
\]'$PS1
;;

xterm-256*)

# https://stackoverflow.com/a/2069095
export PS1='\[\033k\033
\]'$PS1
;;

esac

alias ll='ls -Fhla'
alias lsize='ls -FShla'
alias vi='vim'
alias ss='ssh -C'
alias cp='cp -v'
alias mv='mv -v'
alias rm='rm -iv'
alias grep='grep --color=auto'
# alias grep='grep -n --colour=auto --exclude-dir=\.svn --exclude-dir=\.git'
alias server='open http://localhost:8000 && python -m SimpleHTTPServer'
alias xlock='xlock -mode blank'

Note: See TracTickets for help on using tickets.