Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

GIT 1.8.0 after insert commit comment how to return to CLI

 
Leonidas Savvides
Ranch Hand
Posts: 403
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
GIT 1.8.0

after commands in CLI (COMMAND LINE)
cd C:/Users/User/Documents/PhoneGap/trnotes
git init
git status
git add .
git commit // AFTER INSERT COMMIT's COMMENT WHAT PRESS TO RETURN to CLI and comment done?
 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Leonidas Savvides wrote:
git commit // AFTER INSERT COMMIT's COMMENT WHAT PRESS TO RETURN to CLI and comment done?


You can add a commit message inline. Like this:

 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And for all our sakes: KeepItDown
 
Leonidas Savvides
Ranch Hand
Posts: 403
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if put just

git commit

I get a prompt to insert a message with some comments below it... how this way add comments or return back to git cli?
 
Tim Holloway
Saloon Keeper
Posts: 18303
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It depends on the OS, I think. But in cases where you are entering multi-line input, you can terminate input by typing a single line with a "." in it. Like so:


If that doesn't work, try hitting ENTER twice. Or Ctrl-D, which in Unix/Linux server as an end-of-input signal.
 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It also depends on the editor that is configured for use with git. When a commit is missing a message, git opens up the configured editor where you are expected to write the commit message and close that editor when done. Take a look at the "core.editor" section here http://git-scm.com/book/en/Customizing-Git-Git-Configuration. I highly recommend reading all those chapters in "Pro Git" book. I've found it extremely useful when I was getting started with Git.
 
Leonidas Savvides
Ranch Hand
Posts: 403
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
To: Tim Holloway

nothing happens,... using Git Bash CLI

SEE ATTACHMENT


git.jpg
[Thumbnail for git.jpg]
 
Tim Holloway
Saloon Keeper
Posts: 18303
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think Git launched a copy of the vi editor program. Try hitting the "Esc" key, which should force the cursor to the bottom of the screen. Type ":wq" to write and quit. The semi-colon before the "w" is critical.

Note that you can select almost any editor program you want. Most version control systems use whatever the system environment variable named "EDITOR" is set to, and typically default to vi if it isn't set.
 
Tim Holloway
Saloon Keeper
Posts: 18303
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For more info on git's editor usage: http://digitaldreamer.net/blog/2010/4/7/setting-default-editor-git-commit-messages/
 
Leonidas Savvides
Ranch Hand
Posts: 403
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
worked thks
 
Leonidas Savvides
Ranch Hand
Posts: 403
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
connectng 2 win PCs in local network
if in one pc(USER-HP) i have a repo:
cd C:/Users/User/Documents/PhoneGap/trnotes
To connect with another pc and clone (both installed git bash) this is correct:

git clone User-HP@192.168.10.11:C:/Users/User/Documents/PhoneGap/trnotes theProject

to create theProject in working folder git bash...(from USER-PC pc that accept the clone) (needed have .git this?)???


User-HP@192.168.10.11 ip of source pc

i must be able to write read from windows explorer to
User-HP@192.168.10.11:C:/Users/User/Documents/PhoneGap/trnotes

from USER-PC pc that accept the clone??? for success??
 
Leonidas Savvides
Ranch Hand
Posts: 403
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
user pc source:USER-HP

user pc destination:USER-PC
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic