Skip to content

Commit fa5b8eb

Browse files
committed
translated 2009-01-11-reverting-files.textile
1 parent 664e957 commit fa5b8eb

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
---
22
published: false
33
layout: post
4-
title: reverting files
4+
title: revertir archivos
55
category: beginner
66
---
77

8-
This is a topic that is a constant source of confusion for many git users, basically because there's more than one way to skin the proverbial cat. Let's go over some of the basic commands that you'll need to undo your work.
8+
Este es un tema que constantemente causa confusi&aocute;n para muchos usarios de git, básicamente porque hay mas de una forma de pelar al proverbial gato. Empecemos con los comandos básicos que te ayudarán a deshacer tu trabajo.
99

10-
So, you just want to revert one file back to its original state:
10+
Si solo requieres regresar un archivo a su estado original:
1111

1212
@git checkout <file>@
1313

14-
One problem with this is that you may have is that a file and branch named the same. Since the checkout command is used for both reverting files and swapping out to a different branch, you'll need to use this syntax (thanks, "Norbauer":http://norbauer.com/notebooks/code/notes/git-revert-reset-a-single-file)
14+
Uno de los problemas con este comando es que tu puedes tener un archivo y una rama o _branch_ nombrados igual. El comando checkout puede ser usado tanto para revertir archivos como para moverse a un _branch_ diferente, asi que, necesitaras usar la siguente sintaxis (gracias, "Norbauer":http://norbauer.com/notebooks/code/notes/git-revert-reset-a-single-file)
1515

1616
@git checkout -- <file>@
1717

18-
If you want to throw out all of the changes you've been working on, there's two ways to do that.
18+
Si quieres deshacer todos los cambios en los que has estado trabajando, hay dos formas de hacerlo.
1919

20-
@git checkout -f@ or @git reset --HARD@
20+
@git checkout -f@ o @git reset --HARD@
2121

22-
Once these commands are run you'll lose all of the work that isn't committed in your directory, so make sure to take caution when using them.
22+
Una vez que ejecutes estos comandos, perder&aacute;s todos los cambios que no sean parte de un _commit_, asi que, ten cuidado al usarlos.
2323

24-
Also, be aware that "'git revert' is not equivalent to 'svn revert'!":http://bryan-murdock.blogspot.com/2007/07/git-revert-is-not-equivalent-to-svn.html @git-revert@ is used to reverse commits, something another tip will cover in the future.
24+
Adem&aacute;s, ten en cuenta que "'git revert' no es equivalente a 'svn revert'!":http://bryan-murdock.blogspot.com/2007/07/git-revert-is-not-equivalent-to-svn.html @git-revert@ es usado para deshacer _commits_, algo que ser&aacute; cubierto por otro art&iacute;

0 commit comments

Comments
 (0)