0

I have this:

pick 887b66f add 222 Dziewiecsil to flowers new title
pick dc331cb new name of beginning commit

And I want to get this:

pick dc331cb new name of beginning commit
pick 887b66f add 222 Dziewiecsil to flowers new title

Is there a way to do this in quick way using keyboard shortcuts?

1 Answer 1

1

This page has some examples of how to swap two adjacent lines in the editor vi: http://vim.wikia.com/wiki/Swapping_characters,_words_and_lines

From the link above:

To swap the current line with the one below, tap {esc} and type:

ddp

To swap the current line with the one above, tap {esc} and type:

ddkP

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.