Hi, I normally avoid chatting on Linux topic. and I hate when someone ask his/her problem on chat. I hate because It is one to one communication. I redirect such newbies to mailing list so that other can participate into it. Google index mailing list thread so that other can read such thread after google search. But I found one useful thing in one to one chat system. one of one chat system can be useful for guiding the procedure to newbies.
Today when Abhishek Indoria
(A 14 year old school boy, OLPC contributor) asked me how he can put his source code to some hosting site, I immediately got idea of "Quick Start Chat
". In this system I have explained him each and every steps and he followed all steps. I always wanted to make a tutorial on how to get started with google code hosting but now I have spent 2-3 hour teaching on chat to produce "quick start chat". You can also blog such "quick start chat" as tutorial.
11:22 AM Abhishek: Dude, I know you may be busy...erm..do you know about GIT? or subversion?
11:23 AM me: I have used only svn
but git is something which is better to learn
Abhishek: erm...I need to set up my whole project source code online...
how do I do that?
11:24 AM me: you can do it using sourceforge or Google code hosting
google code hosting use SVG
you can use github too
github use GIT
11:25 AM Abhishek: Sourceforge.net seems good...But, I need to upload the Source in zip or rar or .tar format instead of erm...open editing version like GIT or SVN?
me: no no ,, do not upload tar or zip file
11:26 AM first create a project on these site
and then make a checkout
Abhishek: I have created the project...Checkout?
me: yes,,, checkout the empty project
Abhishek: You know, I feel like stupid as I am only 14 and have loads to learn;)
me: then put your files into it
11:27 AM seee, I learn these things at the age of 24,,,
after making a empty checkout ,, you need to paste files into it
then add files using
11:28 AM svn add filename.cpp
after that you need to comit the files
using "svn ci" command
Abhishek: Ohh..Okay, I am logging into sourceforge...I'll see what I can do, thanks;) Did you read The Lost Symbol by Dan Brown or Code to Zero by Ken Follet?
11:29 AM me: I suggest to use google code hosting,,
I have used it ,, and it has cool features
Abhishek: Erm.. The thing is...
whenever I try Google Code, I can't upload a damn single file.. Dunno why:(
11:30 AM me: Let me guide you,,
Do you have svn installed ??
11:31 AM I reinstalled Ubuntu yesterday,,, SVN Not installed...
me: ok,, just install svn command,,
it wont take much time
11:32 AM mean while go to google code hosting
and create a new project
do you have google wave account ?
11:33 AM Abhishek: No..but I have already created a project..whats google wave?
11:34 AM me: leave google wave,,, Give me link to google project
your project link
Abhishek: wait please.
me: click it,, and go to source tab
11:36 AM Abhishek: okay..
you can see checkout command
11:37 AM me: send me
when I do that...it says
me: see,, you have deleted the trunk
11:39 AM When you create the new project it make 4 directory
me: you it will suggest you to make new project
11:40 AM just delete it and create new project
11:43 AM me: Now go to source code and give me the checkout command
never share password
me: now open a terminal
me: and create a directory where you want to create code
11:45 AM ex
now apply same command by remove trunk out of it
11:47 AM Abhishek: kay
me: show me the output
It will ask for password, it is there at google code website
11:48 AM Abhishek: A imperius/trunk
Checked out revision 1.
now you can see 3 directory
which you have checked out
11:49 AM me: see trunk will be needed for your code
so now cd trunk
11:50 AM me: send me output of these 3 command - pwd, ls -l. svn status
Abhishek: wait, please.
pwd -- /media/Disk 3/BoomingBang/codenamei/imperius/trunk
11:51 AM ls -l : total 0
svn status ... Nothing.
now create a new file
or you can directly paste your code file here
11:52 AM Abhishek: I have folders too...
me: I will show you how to add commit using one file,,
you can do that later
11:53 AM just paste one file
11:54 AM me: give me "svn status"
Abhishek: ? configure
thats the status ^^
11:55 AM me: yes, it is saying, It is that configure is a new file
now you need to add this file to svn system
"svn add configure" command
11:56 AM Abhishek: saying: A configure
I think done.
me: yes,, but change are local
you need to comit the change to mail project
"svn ci filenames" to comit
11:57 AM now use "svn ci configure"
give me the output
Abhishek: --This line, and those below, will be ignored--
There is NANO
11:58 AM okay...
me: yes,, while commiting the files you need to write comments
11:59 AM and then save it
Abhishek: after the saving of file, though I entered it empty;) ...Its saying...Adding configure
Transmitting file data .
Committed revision 2.
check the code,,
12:00 PM It is listing your changes
can you add me in your project for a moment so that I will show something more,,,
Abhishek: wow:) Excellent...thanks..okay, I can add you...
me: this is just 30%
12:01 PM tutorial
see your files at
Abhishek: commitors or owners or contributors?
12:02 PM me: commiter
just add me as commiter
12:03 PM Abhishek: okay.
12:04 PM done
12:05 PM me: just a secound
12:06 PM checking out code now
12:08 PM I have added a new test file,,
12:09 PM just apply svn status command
send me the output
12:11 PM me: svn status --show-updates --verbose
give me output
12:12 PM Abhishek: * test.cpp
2 2 hackerboymayabhi configure
* 1 1 ? .
Status against revision: 3
12:13 PM messed up:)
me: try "svn st -u"
12:14 PM Abhishek: * test.cpp
* 1 .
Status against revision: 3
12:15 PM it means,, your files are not uptodated,,
just apply "svn update" command
to get latest code by other developers
Abhishek: okay..done that.
me: always send output of each command
12:16 PM Abhishek: A test.cpp
Updated to revision 4.
me: see, I have made 2 rivision,,
so now our code is at revision number 4
12:17 PM everytime you update change to trunk, It will make a new revision number
me: anytime you can switch to old revision number too
now you modify test.cpp
12:18 PM Abhishek: how? ci is not working.
me: you have test.cpp file?
12:19 PM me: just open with any editor and add something
add a line
12:20 PM Abhishek: yeah.
me: apply,, svn st
both are same command
12:21 PM me: if you apply svn st command , It will give you something like - "M test.cpp"
give me output of ls, cat test.cpp
12:22 PM Abhishek: ls : configure test.cpp
cat:::::::: test.cpp#include <iostream>
using namespace std;
//hello , code is still incomplete ;
// I know that code is incomplete
12:23 PM me: apply command "svn status"
me: I think you can not saved your changes
12:24 PM what editor you are using?
12:25 PM Abhishek: it says..at revision 5
me: you can commit your changes,, It wont show,,,
why you commited your changes,, :( I didn't told you,,
now modifiy the file again using gedit
12:26 PM done.
me: now apply svn st
12:27 PM or svn status
Abhishek: M test.cpp
me: yes,, This mean,, test.cpp is modified by you,,
12:28 PM you can check the differece
apply "svn diff test.cpp"
Abhishek: Index: test.cpp
- test.cpp (revision 5)
+++ test.cpp (working copy)
@@ -6,4 +6,5 @@
// I know that code is incomplete
+// I know I am a jerk and I don't like C++
12:29 PM me: this is a text based +/- line which will tell you what you have added and deleted
but I will suggest to use
GUI diff tool
12:31 PM me: I saw your comit,, you are now sending log message while comitting
see this url,,
you can see differece b/w comit by you are me
12:32 PM apply command
Abhishek: got that..list
me: export SVN_EDITOR="vi"
you need to set environment variable,,
have you used vi edut???
12:33 PM ever??
Due to rescriction by posterous, I am uanble to post full chat -- read full chat from here - http://groups.google.com/group/iitdlug/browse_thread/thread/bc2439a58381b9f1
Posted via email from LUG@IITD Community Blog