Cursor movement with custom key bindings doesn't work on the prompt buffer

Thanks for the awesome tool.
I added the following config in my init.lisp referring to this post.

(define-configuration buffer
  ((override-map (let ((map (make-keymap "override-map")))
                    (define-key map
                      "C-f" 'nyxt/web-mode:scroll-right
                      "C-b" 'nyxt/web-mode:scroll-left)))))
		      
(define-configuration (prompt-buffer)
    ((default-modes (append '(emacs-mode) %slot-default%))
     (hide-suggestion-count-p t)))

However, the config didn’t work on the prompt buffer for some reasons.
Is this a kind of bug, or issue related to my environment running Nyxt?

OS: kali linux 2022.3 (kali-rolling)
Nyxt version: 2.2.4

You should probably use the 3.0 pre-release (you’re using a rolling release OS after all!), there’s been plenty of changes since then…

Thank you for the reply.
I’ll try the 3.0 pre-release. Could you ever check if the config I attached above work in your environment if possible?

Could you ever check if the config I attached above work in your environment if possible?

It doesn't. web-mode no longer exists. Running describe-command on scroll-right reveals it's now located in document-mode. I'd create my own custom bindings mode and add that to the enabled modes list.

Sorry for the late to reply.
Okay. I’m currently trying to use the latest 3.0 pre-release, but some errors occurred when I cloned the project from Github and ran make all.

Stacktrace1:

Unhandled CFFI-GROVEL:GROVEL-ERROR in thread #<SB-THREAD:THREAD "main thread" RUNNING {1001A40073}>: Couldn't execute "pkg-config": No such file or directory

Stacktrace2:

unhandled condition in --disable-debugger mode, quitting
; 
; compilation unit aborted
;   caught 1 fatal ERROR condition

Compilation failed, see the above stacktrace.

make: *** [makefile:42: nyxt] Error 1

According to the stacktrace2, the error seems to have occurred in line 42 in makefile. The code is as follows:

$(lisp_eval) '(asdf:load-system :nyxt/$(NYXT_RENDERER)-application)'

I assume there is something wrong with the config of renderer, but I have no idea what to set to NYXT_RENDERER. I tried two values, gi-gtk(default) and gtk respectively, but neither of them worked.

Could you give me some advice to make it work?

That is weird - since you're on Kali, which is based on Debian, I would've thought you'd already have pkg-config installed. Is it, though?? dpkg -l pkg-config and check for an ii..

I installed pkg-config as it wasn’t installed by default for some reason.
The version of the package is 0.29.2-1 (arch: amd64).

I ran make all again, and the same error as stacktrace2 still occurs.
The command output filtered by “error” is as follows:

Unhandled CFFI-GROVEL:GROVEL-ERROR in thread #<SB-THREAD:THREAD "main thread" RUNNING {100B648073}>: Subprocess #<UIOP/LAUNCH-PROGRAM::PROCESS-INFO {1005E57193}>
 exited with error code 1
0: (SB-DEBUG::DEBUGGER-DISABLED-HOOK #<CFFI-GROVEL:GROVEL-ERROR "~a" {1005E651D3}> #<unused argument> :QUIT T)
1: (SB-DEBUG::RUN-HOOK SB-EXT:*INVOKE-DEBUGGER-HOOK* #<CFFI-GROVEL:GROVEL-ERROR "~a" {1005E651D3}>)
2: (INVOKE-DEBUGGER #<CFFI-GROVEL:GROVEL-ERROR "~a" {1005E651D3}>)
3: (ERROR CFFI-GROVEL:GROVEL-ERROR :FORMAT-CONTROL "~a" :FORMAT-ARGUMENTS (#<(SIMPLE-BASE-STRING 347) Subprocess #<UIOP/LAUNCH-PROGRAM::PROCESS-INFO {1005E57193}>
 exited with error code 1
4: (CFFI-GROVEL:GROVEL-ERROR "~a" #<(SIMPLE-BASE-STRING 347) Subprocess #<UIOP/LAUNCH-PROGRAM::PROCESS-INFO {1005E57193}>
 exited with error code 1
;   caught 1 fatal ERROR condition
make: *** [makefile:42: nyxt] Error 1

My first instinct is, did you run sudo ldconfig afterwards?

Next question: did you run sudo apt install sbcl libwebkit2gtk-4.0-dev gobject-introspection glib-networking gsettings-desktop-schemas libfixposix-dev pkg-config xclip enchant-2 libssl-dev like in the INSTALL file? That would’ve solved the pkg-config problem earlier, so you might still be missing a dependency…

Also, did you run it with -IC aka --no-config --no-auto-config?

did you run sudo ldconfig afterwards?

No, I didn't.

did you run sudo apt install sbcl libwebkit2gtk-4.0-dev gobject-introspection glib-networking gsettings-desktop-schemas libfixposix-dev pkg-config xclip enchant-2 libssl-dev like in the INSTALL file?

No, I only installed sbcl and pkg-config, and I think the others may be missing.
I'll run the command.

did you run it with -IC aka --no-config --no-auto-config ?

No, I just ran make all without any options.

Just to make sure I'm not mistaken, running sudo apt install sbcl libwebkit2gtk-4.0-dev gobject-introspection glib-networking gsettings-desktop-schemas libfixposix-dev pkg-config xclip enchant-2 libssl-dev will solve this issue?

No, I just ran make all without any options.

Sorry, I forgot you were still stuck on the compilation stage.

Just to make sure I’m not mistaken

Yes, it's a good idea to install all the dependencies. Perhaps the team will need to make the errors for missing dependencies more clear or something..

I installed all necessary dependencies, and cursor movement with C-f and C-b in prompt buffer is working as expected now.

I think it’s weird those key bindings didn’t work on my environment when I installed ver.2.2.4.

When I asked the same question on GitHub, one of the Nyxt developers said they worked perfectly on his environment. (His version was 2.2.4 too.)

It might be because I downloaded a complete bundle from this url.

I assume there might’ve been some differences between the code on GitHub and the one provided from the url. He might’ve built the code like I did this time.