I’m looking for my last command. Where is it?

Sulstice
1 min readApr 11, 2021

You hire a cheminformatician — she or he will come with a bag of tricks. We’ve seen things down there in the data. Here’s a 1 minute trick for my fellow peers that I’ve seen — as a fun thing :).

So let’s start in linux or mac os (idk about windows — I’m not a windows user):

$ echo 'where is that electron?'
>>> where is that electron?

Then type in history and my last line:

$ history>>> history
>>> 10260 echo 'where is that electron?'

Now let’s put a space before the echo command to treat it as a comment — but it still runs.

$  echo 'it is here'
>>> it is here

Now type history

>>> history
>>> 10260 echo 'where is that electron?'

It’s not there, the last command wasn’t logged because it thought it was a command in lieu of the presiding space taken at the start of the line.

--

--