2014-03-28 60 views
0

使用Windows 8,BitNami Rubystack,Ruby 2.0.0p353,Rails 4.0.3。我經常使用Git分支並執行更改。我正在研究一個名爲device-enhanced(我相信我是反正......)的分支。我像往常一樣去做改變。 Git添加和提交工作,然後結帳說主人是最新的。變回分支機構,它也是最新的?據統計,我改變了12個文件137個變更和133個刪除。最新情況如何?我做錯了什麼?謝謝...Git發現變化,然後說所有內容都是最新的

D:\BitNami\rubystack-2.0.0-11\projects\anyapplication>git add . 
warning: LF will be replaced by CRLF in Gemfile.lock. 
warning: LF will be replaced by CRLF in app/views/layouts/_messages.html.erb. 
warning: LF will be replaced by CRLF in app/views/layouts/application.html.erb. 
warning: LF will be replaced by CRLF in app/views/users/edit.html.erb. 
warning: LF will be replaced by CRLF in app/views/users/show.html.erb. 

D:\BitNami\rubystack-2.0.0-11\projects\anyapplication>git commit -m "Device enhanced but model not yet renamed" 
[eliminate-rolify warning: LF will be replaced by CRLF in Gemfile.lock. 
warning: LF will be replaced by CRLF in app/views/layouts/_messages.html.erb. 
warning: LF will be replaced by CRLF in app/views/layouts/application.html.erb. 
warning: LF will be replaced by CRLF in app/views/users/show.html.erb. 
warning: LF will be replaced by CRLF in app/views/users/edit.html.erb. 
926a210] Device enhanced but model not yet renamed 
warning: LF will be replaced by CRLF in Gemfile.lock. 
warning: LF will be replaced by CRLF in app/views/layouts/_messages.html.erb. 
warning: LF will be replaced by CRLF in app/views/layouts/application.html.erb. 
warning: LF will be replaced by CRLF in app/views/users/edit.html.erb. 
warning: LF will be replaced by CRLF in app/views/users/show.html.erb. 
12 files changed, 137 insertions(+), 133 deletions(-) 
rewrite app/views/layouts/_messages.html.erb (83%) 
create mode 100644 app/views/layouts/_shim.html.erb 
create mode 100644 app/views/users/edit.html.erb 
rewrite db/seeds.rb (81%) 

D:\BitNami\rubystack-2.0.0-11\projects\anyapplication>git checkout master 
Switched to branch 'master' 
Your branch is up-to-date with 'origin/master'. 

D:\BitNami\rubystack-2.0.0-11\projects\anyapplication>git merge device-enhanced 
Already up-to-date. 

D:\BitNami\rubystack-2.0.0-11\projects\anyapplication>git push -u origin master 
Branch master set up to track remote branch master from origin. 
Everything up-to-date 

D:\BitNami\rubystack-2.0.0-11\projects\anyapplication>git status 
On branch master 
Your branch is up-to-date with 'origin/master'. 

nothing to commit, working directory clean 
+0

也許你對主人承諾。 – jcm

+0

我知道這是可能的。即便如此,推送解決方案不會更新嗎? –

回答

0

事實證明,我合併在一箇舊的分支。這減少了我對正確分支所做的所有更改。爲了獲得這些更改,我從當前備份中恢復了應用程序。在恢復的文件上發出git狀態顯示了正確的分支。

0

我不知道,但似乎你需要做一個git push origin device-enhancedgit checkout master之前。其他的事情是,git checkout master做完之後git pull之前merge它與你的branch。請記住,有時git失去了自己,你可以刪除你的folder並做一個新的git clone "git_path"作爲唯一可能的解決方案。

相關問題