Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

file-name element doesn't update when saving under INS mode #4719

Closed
Hpmason opened this issue Nov 12, 2022 · 2 comments
Closed

file-name element doesn't update when saving under INS mode #4719

Hpmason opened this issue Nov 12, 2022 · 2 comments
Labels
A-gui Area: Helix gui improvements C-bug Category: This is a bug

Comments

@Hpmason
Copy link

Hpmason commented Nov 12, 2022

Summary

Saving file while in insert mode doesn't properly update the file-name [+]. It seems to mostly be just a graphical error, but on Linux (at least the machine I was SSHed into), saving in insert mode saves the file, but helix doesn't let you quit.
(And the saving while in insert mode is done with key mapping)

Reproduction Steps

config.toml:

[keys.insert]
 C-s = ":w"

I tried this:

  1. Open file hx temp.txt
  2. Enter ins mode i
  3. Enter text "hello world"
  4. While still in insert mode try to save C-s
  5. Quit out of file ESC, :q

I expected this to happen:
File would save and [+] would go away

Instead, this happened:
On windows:
File successfully saved, but the [+] did not successfully update on the file-name status bar.

On Linux (at least though SSH)
[+] graphic did not update, but the following message appeared under the status bar: 'temp.txt' written 4L 34B.
After exiting INS mode and trying to :q I get the following message: 1 unsaved buffer(s) remaining: ["temp.txt"]. Force quitting exits the editor and the file seems to have saved correctly.

Helix log

~/.cache/helix/helix.log
2022-11-12T04:17:39.287 helix_view::clipboard::provider [WARN] No clipboard provider found! Yanking and pasting will be internal to Helix
2022-11-12T04:17:53.244 helix_view::editor [ERROR] editor error: 1 unsaved buffer(s) remaining: ["temp.txt"]
2022-11-12T04:18:09.911 helix_view::clipboard::provider [WARN] No clipboard provider found! Yanking and pasting will be internal to Helix
2022-11-12T04:20:13.897 helix_view::clipboard::provider [WARN] No clipboard provider found! Yanking and pasting will be internal to Helix
2022-11-12T04:20:23.360 helix_view::editor [ERROR] editor error: 1 unsaved buffer(s) remaining: ["temp.txt"]
2022-11-12T04:20:28.330 helix_view::clipboard::provider [WARN] No clipboard provider found! Yanking and pasting will be internal to Helix
2022-11-12T04:20:41.857 helix_view::editor [ERROR] editor error: 1 unsaved buffer(s) remaining: ["temp.txt"]
2022-11-12T04:24:58.337 helix_view::clipboard::provider [WARN] No clipboard provider found! Yanking and pasting will be internal to Helix
2022-11-12T04:25:09.863 helix_view::editor [ERROR] editor error: 1 unsaved buffer(s) remaining: ["temp.txt"]
2022-11-12T04:26:34.739 helix_view::clipboard::provider [WARN] No clipboard provider found! Yanking and pasting will be internal to Helix
2022-11-12T04:28:19.549 helix_view::editor [ERROR] editor error: 1 unsaved buffer(s) remaining: [".cache/helix/helix.log"]

Platform

Windows + Linux over SSH

Terminal Emulator

Windows Terminal & xterm-256color over SSH

Helix Version

helix 22.08.1 (001e4e3)

@Hpmason Hpmason added the C-bug Category: This is a bug label Nov 12, 2022
@vanarok
Copy link
Contributor

vanarok commented Nov 12, 2022

I have this problem too:
config.toml

[keys.insert]
a = { k = ["normal_mode", ":update"] }

@kirawi kirawi added the A-gui Area: Helix gui improvements label Nov 15, 2022
swork1 added a commit to swork1/helix that referenced this issue Nov 16, 2022
@archseer
Copy link
Member

Duplicate of #3501

@archseer archseer marked this as a duplicate of #3501 Nov 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-gui Area: Helix gui improvements C-bug Category: This is a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants