Created
August 3, 2014 01:38
-
-
Save memuller/0d4e4f5b58f0782023e3 to your computer and use it in GitHub Desktop.
Steps to replica weird problems with GIT checkout @locaweb.
This file contains 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
#!/bin/sh | |
cd ~ | |
# clona o repositório problemático | |
git clone repo test_repo | |
cd test_repo | |
# git status mostrará arquivos deletados, mesmo o repositório tendo acabado de ser clonado/checkoutado. | |
# ls mostrará que de fato os arquivos não existem, também. | |
git status | |
# checkout, reset | |
git checkout . | |
git reset --hard | |
# arquivos permanecem "deletados" | |
git status | |
# checkout manual de um destes arquivos não funciona também. git status ainda exibirá que o arquivo está deletado. | |
git checkout wp-content/themes/rb2portal/functions.php | |
git status | |
# somente os arquivos mostrados como deletados no status inicial possuem este problema; checkout funciona normalmente com outros arquivos. por exemplo: | |
echo "" > wp-content/themes/rb2portal/single.php #remove conteúdo | |
cat wp-content/themes/rb2portal/single.php #okay, conteúdo foi removido | |
git checkout . | |
cat wp-content/themes/rb2portal/single.php #conteúdo foi restaurado, exatamente como deveria ser. | |
# os arquivos afetados são os seguintes: | |
# wp-content/themes/rb2portal/acf_time_picker/js/option.php | |
# wp-content/themes/rb2portal/external/acf_time_picker/css/admin.php | |
# wp-content/themes/rb2portal/external/acf_time_picker/system.php | |
# wp-content/themes/rb2portal/external/eventos-post-type.php | |
# wp-content/themes/rb2portal/functions.php | |
# wp-content/themes/rb2portal/tag.php | |
# wp-content/themes/twentyeleven/colors/user.php | |
# wp-content/themes/twentyeleven/content-gallery.php | |
# wp-content/themes/twentyeleven/content-image.php | |
# wp-content/themes/twentyeleven/content-link.php | |
# wp-content/themes/twentyeleven/images/functions.php | |
# wp-content/themes/twentyeleven/inc/option.php | |
# wp-content/themes/twentyfourteen/image.php | |
# wp-content/themes/twentyfourteen/languages/info.php | |
# wp-content/themes/twentyfourteen/languages/options.php | |
# wp-content/themes/twentyfourteen/sidebar-content.php | |
# wp-content/themes/twentyfourteen/taxonomy-post_format.php | |
# wp-content/themes/twentyten/archive.php | |
# wp-content/themes/twentyten/author.php | |
# wp-content/themes/twentyten/images/dump.php | |
# wp-content/themes/twentyten/images/headers/include.php | |
# wp-content/themes/twentyten/loop-single.php | |
# wp-content/themes/twentyten/sidebar.php | |
# wp-content/themes/twentythirteen/author-bio.php | |
# wp-content/themes/twentythirteen/content-none.php | |
# wp-content/themes/twentytwelve/comments.php | |
# wp-content/themes/twentytwelve/index.php | |
# wp-content/themes/twentytwelve/js/diff.php | |
# wp-content/themes/twentytwelve/js/menu.php | |
# wp-content/themes/twentytwelve/single.php |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment