This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hola.rb queda así: | |
nombre = ARGV.first || "Mundo" | |
puts "Hola, #{nombre}!" | |
git add hola.rb | |
git commit -m "Ups, no queríamos este commit" | |
git revert HEAD --no-edit | |
[main 8b71812] | |
git log --oneline |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git tag v1 | |
bash | |
git checkout v1^ # o v1~1 | |
cat hello.rb | |
hello.rb | |
cat hello.rb. | |
bash |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hello.rb | |
nombre = ARGV.first || "Mundo" | |
puts "Hola, #{nombre}!" | |
ruby hello.rb Ana | |
bash | |
git add hello.rb |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git init): | |
cd work/hola | |
💎 2. Editar el archivo hello.rb | |
Abre el archivo hello.rb en tu editor y reemplaza su contenido con: | |
puts "Hola, #{ARGV.first}!" |