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

feat(normal)!: remove the gs, g? normal command #28489

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions runtime/doc/news.txt
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ The following changes may require adaptations in user config or plugins.
• |nvim_open_win()| now blocks all autocommands when `noautocmd` is set,
rather than just those from setting the `buffer` to display in the window.

• Removed the |gs| normal command.
dundargoc marked this conversation as resolved.
Show resolved Hide resolved

==============================================================================
BREAKING CHANGES IN HEAD *news-breaking-dev*

Expand Down
5 changes: 2 additions & 3 deletions runtime/doc/various.txt
Original file line number Diff line number Diff line change
Expand Up @@ -515,16 +515,15 @@ gO Show a filetype-specific, navigable "outline" of the

Currently works in |help| and |:Man| buffers.

[N]gs *gs* *:sl* *:sleep*
*:sl* *:sleep*
:[N]sl[eep] [N][m] Do nothing for [N] seconds, or [N] milliseconds if [m]
was given. "gs" always uses seconds.
was given.
Default is one second. >
:sleep "sleep for one second
:5sleep "sleep for five seconds
:sleep 100m "sleep for 100 milliseconds
10gs "sleep for ten seconds
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line 525, which refers to gs, should go as well.

< Can be interrupted with CTRL-C.
"gs" stands for "goto sleep".
While sleeping the cursor is positioned in the text,
if at a visible position.
Queued messages are processed during the sleep.
Expand Down
2 changes: 2 additions & 0 deletions runtime/doc/vim_diff.txt
Original file line number Diff line number Diff line change
Expand Up @@ -675,6 +675,8 @@ Highlight groups:
\|setlocal winhighlight=StatusLine:StatusLineTerm,StatusLineNC:StatusLineTermNC
\|else|setlocal winhighlight=|endif
<
Normal commands:
dundargoc marked this conversation as resolved.
Show resolved Hide resolved
*gs*

Options:
*'aleph'* *'al'*
Expand Down
5 changes: 0 additions & 5 deletions src/nvim/normal.c
Original file line number Diff line number Diff line change
Expand Up @@ -5525,11 +5525,6 @@ static void nv_g_cmd(cmdarg_T *cap)
nv_gomark(cap);
break;

// "gs": Goto sleep.
case 's':
do_sleep(cap->count1 * 1000);
break;

// "ga": Display the ascii value of the character under the
// cursor. It is displayed in decimal, hex, and octal. -- webb
case 'a':
Expand Down
2 changes: 1 addition & 1 deletion test/old/testdir/test_sleep.vim
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ func! Test_sleep_bang()
call s:assert_takes_longer('sl 50m', 50)
call s:assert_takes_longer('sl! 50m', 50)
call s:assert_takes_longer('1sleep', 1000)
call s:assert_takes_longer('normal 1gs', 1000)
" call s:assert_takes_longer('normal 1gs', 1000)
endfunc

" vim: shiftwidth=2 sts=2 expandtab