2

I find myself wanting to type .. instead of cd .. a lot, so I created an alias for it in one my of my shells. It works as expected, and it doesn't seem to break basic cd and ls usage.

Is doing this a bad idea?

Jeremy
  • 123
  • 4
  • 2
    Is it a bad idea? Only in the sense that you're looking for a shortcut to counter carelessness instead of developing better habits. – John Gardeniers Oct 20 '10 at 02:45
  • Good point. At first I thought that something so simple wouldn't ruin me, but it probably will. Thanks. – Jeremy Oct 20 '10 at 03:05

3 Answers3

4

It won't break anything, but aliasing something as basic as cd .. might lead to bad habits. Really, you're better off training your fingers to do the right thing.

Also, what happens when you move to a new system, or get a new job, or need to maintain 1000 systems. You'll need to alias .. again, which can be a pain.

Many of us have done that in the past with other aliases, and learned that this was a bad idea, sometimes through a harsh experience.

Stefan Lasiewski
  • 23,667
  • 41
  • 132
  • 186
2

Nothing uses .. as a command, so this is acceptable.

Ignacio Vazquez-Abrams
  • 45,939
  • 6
  • 79
  • 84
1

Is doing this a bad idea?

Yes

Belmin Fernandez
  • 10,799
  • 27
  • 84
  • 148