Skip to main content
fix the wrong edit that I had rejected in review but another editor had accepted
Source Link
Anthony Geoghegan
  • 11.9k
  • 5
  • 52
  • 57

First, type: history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d $line ;1800; done

If you wannawant to delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted.

For example :

$ for line in $(seq 1800 1816) ; do history -d $line ;1800; done

First, type: history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d $line ; done

If you wanna delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted.

For example :

$ for line in $(seq 1800 1816) ; do history -d $line ; done

First, type: history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d 1800; done

If you want to delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted.

For example :

$ for line in $(seq 1800 1816) ; do history -d 1800; done
Corrected logical error
Source Link
SLePort
  • 15.4k
  • 3
  • 38
  • 45

First, type: $history andhistory and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d $line ; done

$ for line in $(seq 1800 1815) ; do history -d $line ; done

If you wanna delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted. For

For example: $ for line in $(seq 1800 1816) ; do history -d $line ; done:

$ for line in $(seq 1800 1816) ; do history -d $line ; done

First, type: $history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d $line ; done

If you wanna delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted. For example: $ for line in $(seq 1800 1816) ; do history -d $line ; done

First, type: history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d $line ; done

If you wanna delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted.

For example :

$ for line in $(seq 1800 1816) ; do history -d $line ; done

First, type: $history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d 1800$line ; done

If you wanna delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted. For example: $ for line in $(seq 1800 1816) ; do history -d 1800$line ; done

First, type: $history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d 1800 ; done

If you wanna delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted. For example: $ for line in $(seq 1800 1816) ; do history -d 1800 ; done

First, type: $history and write down the sequence of line numbers you want to remove.

To clear lines from let's say line 1800 to 1815 write the following in terminal:

$ for line in $(seq 1800 1815) ; do history -d $line ; done

If you wanna delete the history for the deletion command, add +1 for 1815 = 1816 and history for that sequence + the deletion command will be deleted. For example: $ for line in $(seq 1800 1816) ; do history -d $line ; done

Source Link
Ghassan Zein
  • 4.2k
  • 4
  • 20
  • 30
Loading