Community gatherings on Freenode at #tinycorelinux (webchat)
precmd() { if [ ! "${PWD##$HOME}" ]; then MC_PWD="~"; else [ "${PWD##$HOME/}" = "$PWD" ] && MC_PWD="$PWD" || MC_PWD="~/${PWD##$HOME/}"; fi; echo "$USER@$(hostname -s):$MC_PWD"; pwd>&6; kill -STOP $$; }; PRECMD=precmd; PS1='$($PRECMD)$ '
# Stop Midnight Commander from spamming the command history files.alias mc='env HISTFILE=/dev/null mc'
# Fix the desktops popup menu.[ -f ~/.wmx/Applications/mc ] && echo -e "#!/bin/sh\nenv HISTFILE=/dev/null xterm -e mc" > ~/.wmx/Applications/mc
# Fix the wbar icon.DESKTOP="/usr/local/share/applications/mc.desktop"# Replace the link with a file so we can edit it.[ -L "$DESKTOP" ] && sudo busybox cp "$(readlink "$DESKTOP")" "$DESKTOP"[ -f "$DESKTOP" ] && sudo sed -i 's|^Exec=.*|Exec=~/.wmx/Applications/mc|' "$DESKTOP"[ -f "$DESKTOP" ] && wbar_rm_icon mc[ -f "$DESKTOP" ] && wbar_update.sh mc
chmod 775 .X.d/FixMC./.X.d/FixMC