LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 02-02-2021, 08:15 AM   #1
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
Midnight Commander 4.8.26 keymap not working


Since the recent update, Midnight Commander is no longer honoring my keymap. The custom bindings are stored in ~/.config/mc/mc.keymap, and I've updated the file to bring in the latest changes from /etc/mc/mc.default.keymap. The main change in my file is to redefine ChangePanel from tab to ctrl-f, and then Complete from alt-tab to tab. With this latest version, ctrl-f doesn't do anything, and the tab key changes panels despite my settings. What I've done to try to debug:
  1. Removed any potential collisions between my custom bindings and existing ones in mc.keymap.
  2. Changed some other keybindings in the file. Those didn't have any effect either.
  3. Tried manually specifying the keymap file at launch using the -K option. Still no effect.
So it seems like mc is just completely ignoring the keymap file now. Is anyone else having the same issue?
 
Old 02-02-2021, 08:43 AM   #2
Chuck56
Member
 
Registered: Dec 2006
Location: Colorado, USA
Distribution: Slackware
Posts: 930

Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
Have you tried removing the files in ~/.cache/mc, /root/.cache/mc, /tmp/mc-[user] &/or /tmp/mc-root files yet?

Not sure that would help but maybe...
 
Old 02-02-2021, 09:10 AM   #3
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Original Poster
Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
Quote:
Originally Posted by Chuck56 View Post
Have you tried removing the files in ~/.cache/mc, /root/.cache/mc, /tmp/mc-[user] &/or /tmp/mc-root files yet?

Not sure that would help but maybe...
Just did. No change. Have you tried reproducing the problem on your end?
 
Old 02-02-2021, 09:25 AM   #4
Chuck56
Member
 
Registered: Dec 2006
Location: Colorado, USA
Distribution: Slackware
Posts: 930

Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
I normally don't change key mappings. I did just test it and it's not working for me either.
 
1 members found this post helpful.
Old 02-02-2021, 09:28 AM   #5
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Original Poster
Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
Quote:
Originally Posted by Chuck56 View Post
I normally don't change key mappings. I did just test it and it's not working for me either.
Thanks for the confirmation. I just reverted to the previous version, and custom keybindings work again. I guess I should file a bug report upstream.

Last edited by montagdude; 02-02-2021 at 09:41 AM.
 
Old 02-02-2021, 09:41 AM   #6
Chuck56
Member
 
Registered: Dec 2006
Location: Colorado, USA
Distribution: Slackware
Posts: 930

Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
I'm not sure if this is a change in mc but after playing around some more I'm able to get custom key mappings to work.

I removed the symbolic link /etc/mc/mc.keymap and created a modified copy of /etc/mc.default.keymap as ~/.config/mc/mc.keymap. It honored my change as a regular user. When I used mc as root the unaltered/original keymap was in effect.

Maybe the symlink is the issue?
 
Old 02-02-2021, 09:48 AM   #7
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Original Poster
Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
Quote:
Originally Posted by Chuck56 View Post
I'm not sure if this is a change in mc but after playing around some more I'm able to get custom key mappings to work.

I removed the symbolic link /etc/mc/mc.keymap and created a modified copy of /etc/mc.default.keymap as ~/.config/mc/mc.keymap. It honored my change as a regular user. When I used mc as root the unaltered/original keymap was in effect.

Maybe the symlink is the issue?
Hm, it doesn't work here. I installed 4.8.26 again and removed the symbolic link, and my keymap still has no effect. It works fine on 4.8.25. In any case, the user keymap should take precedence over the system one. Just out of curiosity, what did you change in the keymap file to test?
 
Old 02-02-2021, 09:52 AM   #8
Chuck56
Member
 
Registered: Dec 2006
Location: Colorado, USA
Distribution: Slackware
Posts: 930

Rep: Reputation: 479Reputation: 479Reputation: 479Reputation: 479Reputation: 479
I change the quit keymap:

to: Quit = alt-q
from: Quit = f10
 
Old 02-02-2021, 09:59 AM   #9
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Original Poster
Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
Quote:
Originally Posted by Chuck56 View Post
I change the quit keymap:

to: Quit = alt-q
from: Quit = f10
Yeah, still no change on my end. That works with 4.8.25 but not 4.8.26, regardless of whether the /etc/mc/mc.keymap symlink is present.
 
Old 02-02-2021, 12:20 PM   #10
shruggy
Senior Member
 
Registered: Mar 2020
Posts: 3,678

Rep: Reputation: Disabled
Could it have something to do with #4107? Curiously, the ticket says: "This is the result of #3672."
 
Old 03-30-2023, 10:25 AM   #11
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Original Poster
Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
Circling back to this thread, I figured out the issue. The name of the top section in mc.keymap changed names from [main] to [filemanager] in the most recent versions of mc, and I failed to update that in my user config (~/.config/mc/mc.keymap). A vimdiff comparing my user config to /etc/mc/mc.default.keymap revealed that right away. Should have checked that earlier.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
midnight commander keys not working iomari Linux - Desktop 2 12-26-2018 12:42 AM
[SOLVED] OpenSUSE 12.2 midnight commander from repository very old and not working good ni_hao SUSE / openSUSE 2 11-27-2012 05:36 AM
Changing Linux keymap to reflect dual-booted WinXP keymap AbuKaidman Linux - Newbie 2 07-18-2009 03:05 AM
mc(midnight commander) - using vim to edit does not change the file on ftp rlee923 Linux - Software 2 10-18-2007 05:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:23 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration