I have a very large text file, and I want to select part of the text (range of lines. Example: from line 10000 to line 40000 and the text has 100 thousand lines). But I do not see any option in these editors (gedit, pluma, nemo) that allows me to make this selection (only "select all or Ctrl+A" option).

I would like to know how to do it and in case they do not allow, what other similar text editor (GUI) exists that allows me to make this selection.



I already know the alternatives in the command line. The answer I ask is only in the text editors mentioned (or in other similar ones, native Linux applications. Exclude "vim" or "nano".)

I have installed the additional plugins of gedit and pluma, but I also do not see that they have this possibility of selection

This option can be found in notepad++. I installed a clone called notepadqq, but it does not have this option

3 Answers 3


vim can certainly do this: in command mode, enter 10000G hit V then 40000G. Voilà, requested selection.

However, what do you want to do with the selection?

  • select from the line (example 1000) to another line (example 4000) and delete them, to insert in this place other lines of another text. I would prefer it not to be with vim
    – acgbox
    Commented Jun 15, 2018 at 16:12
  • Well, pick an editor and ask a question about how to do this specific action with this specific editor. Don't ask countless strangers to read your mind. Commented Jun 15, 2018 at 16:14
  • Already did. It is in the question (nemo, gedit, pluma)
    – acgbox
    Commented Jun 15, 2018 at 16:15

From the command line (one of several methods):

head -number_of_lines < file.txt > file.new


In sublime text:

Ctrl-G to go to the last line you want to select, by number.
Edit > Mark > Set Mark to set your selection-end marker.
Ctrl-G (or Ctrl-Home) to go to the first line you want to select.
Edit > Mark > Select to Mark

In vscode:

go to line should select text from the current cursor when holding down shift

  • Links change all the time. Please provide the essential steps in your answer so that one can replicate the solution without clicking on the link. Keep the links as references. Link only answers may be deleted. I am down voting this as a link only answer.
    – user68186
    Commented Mar 17, 2022 at 22:20
  • answer update. if you are not satisfied, please notify me to expand it even more
    – acgbox
    Commented Mar 17, 2022 at 22:36
  • 1
    I have removed my down vote. Feel free to expand and improve the answer.
    – user68186
    Commented Mar 17, 2022 at 23:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .