----BEGIN CLASS---- [13:28] #startclass [13:28] Yes, I will but just wanted to know, anything special I missed messifc [13:28] Roll Call [13:28] Santosh Kumar Shaw [13:28] Messi Fc [13:28] Abhinav Shirur [13:28] Jason Braganza [13:28] Devesh Verma [13:28] Abdul Wahab Abrar [13:28] Akash pathak [13:28] Shankar Jha [13:28] Deepika Upadhyay [13:28] Samridhi Agarwal [13:28] Dhairyya Agarwal [13:28] Anu Kumari Gupta [13:28] Saikat Dey [13:28] Soumam Banerjee [13:28] Shivam Ahirao [13:28] Apoorv Goel [13:28] PradhvanBisht [13:28] Mohsin Mumtaz [13:28] Bhavin Gandhi [13:28] pooja kumari singh [13:28] Naveej Ahamed [13:28] Amarjeet singh [13:28] Robin Schubert [13:28] Suraj Ghimire [13:28] Chiranjeev Gupta [13:28] sayalee raut [13:28] Ashwani Kumar Gupta [13:28] Kshithij Iyer [13:28] Kshitij [13:28] Akshay gaikwad [13:29] Jitesh pabla [13:29] Mukund Banka [13:29] Ranjeet kumar [13:29] Sakshi Saraswat [13:29] Nishanta sarma [13:29] Abhishek Singh [13:29] Ratan Kulshreshtha [13:29] Mohd Omama [13:29] Mayur khomane [13:29] Amit Kokitkar [13:29] Wrik Bhadra [13:29] Niranjana Deshpande [13:29] Priyansh sourav [13:29] Abhilash Raj [13:30] Kishore Saldanha [13:30] ABHISHEK SHARMA [13:30] Kushal Das [13:30] Anupama Shipurkar [13:30] ABHISHEK SHARMA [13:30] Arush Salil [13:30] Prakhar Shukla [13:30] Priyanka Sharma [13:30] Tridev Guha [13:31] sandeep kumar choudhary [13:31] Pritam Bankar [13:31] Soumam Banerjee [13:31] deep [13:31] Rimsha Khan [13:32] Balaji [13:32] I hope everyone is done. [13:32] Akshay Shipurkar [13:33] Ishank Gupta [13:33] Sumit Sardana [13:33] Shashank Kumar [13:33] Today we will learn about editors. [13:33] ok [13:33] vim [13:34] This is a tool for which people may start a new war, millions of hours already waster to figure out which one is better. [13:34] Atom [13:34] nano [13:34] sublime [13:34] emacs and gedit are missing out [13:34] Ravindra Lakal [13:34] vim vs emacs :) [13:35] asraisingh: I guess it's lime in Linux. [13:35] Sublime is windows [13:35] [13:35] This is better. [13:36] In our session we will only learn about vim, feel free to learn all the other ones of your own time. [13:38] Let us all open our terminal [13:38] Today we all will type along, means it will be a live session [13:40] Or we don't. [13:40] I will keep the session running, but you follow from the log here https://dgplug.org/irclogs/kushal_vi_1stclass.log [13:40] Yes, live session [13:41] ok [13:41] Search for 23:07:33 and then read from there. [13:41] If you have any doubt, type ! here, we will take questions [13:41] Alright [13:41] ! [13:42] next [13:42] ! [13:42] next [13:42] what is going on? [13:42] If we want we can see from here also, like you'll be also posting the live session , right? [13:43] avik, vim session. [13:43] kushal, thanks! [13:43] zetathon__, nope. Not today. [13:43] ! [13:43] ok [13:43] Sorry late again, I am actually working in night shift so.. Bhavesh Gupta [13:43] zetathon__, We will do that in the coming days. [13:43] kushal, what to be done by us? [13:43] any link? [13:43] avik, start following https://dgplug.org/irclogs/kushal_vi_1stclass.log [13:43] next [13:43] by default vi editor will be present in all linux or we have to install? [13:43] ok thanks kushal [13:44] theAtom, It is generally there. [13:44] kushal, okay. [13:44] ! [13:44] next [13:44] What happens when we edit in .vimrc [13:45] ! [13:45] ! [13:45] deepika, vimrc is the configuration file for vim. Skip that for now, edit any other file. [13:45] like [13:45] vim hello.txt [13:45] ! [13:45] next [13:45] ! [13:46] okay thanks [13:46] ! [13:46] In my system, there are both vi and vim. vi is a symlink of ex. Is ex used in anywhere? [13:46] ! [13:47] ! [13:48] SpEcHiDe, maybe, I don't know. [13:48] next [13:48] What is the difference between vi and vim, it looks the same? [13:49] neer, for most systems yes, but vi used to be the old one, vim is newer. [13:49] vi enhanced [13:49] next [13:49] So, do we have to refer the whole thing from the log? And this is just going to be a q/a session? [13:50] ! [13:50] skarpy, you will have to try the commands from the log, if you have questions, we will take it here. [13:50] next [13:50] kushal: Are we suppose to keep on following the log and carry out steps accordingly? When should we stop? [13:50] ! [13:50] Raut, When the logs end. [13:50] next [13:50] ! [13:51] ! [13:51] My question has been asked and answered already, thanks. [13:51] next [13:51] next [13:51] why shall we use this? i mean we can use normal leafpad also to write without using commands? [13:52] no doubt [13:52] ooja@pooja-Inspiron-3521 ~ $ vim hello.txt [13:52] The program 'vim' can be found in the following packages: [13:52] * vim [13:52] * vim-gnome [13:52] * vim-tiny [13:52] * vim-athena [13:52] * vim-gtk [13:52] * vim-nox [13:52] Try: sudo apt-get install [13:52] ! [13:52] sudo apt-get install vim [13:52] i have to install the package? [13:52] yup [13:52] ! [13:52] thanks [13:52] poojaencoded, 2 things, you are talking out of order, also use a pastebin like paste.fedoraproject.org to show so many lines [13:52] soumam_, correct, but think about a situation where you will have to login to a server and work [13:53] and also vim is very powerful [13:53] poojaencoded: yes and chhose vim [13:53] next [13:53] ! [13:53] ok, kushal !we will learn its power :) [13:53] poojaencoded, yes, install vim [13:53] next [13:53] Edit mode turns on with a/d/w keys also. Why is that? [13:54] done [13:54] ashwanig, each of those keys have some meaning, you will learn about those slowly. [13:54] next [13:54] kushal, yesterday i'm playing vim adventure there is B and b command two commands but i am not able to figure out the difference. Please Help! [13:54] My question is not related to vim rather it's bash scripting related from previous day. Can I ask it now? [13:54] ashwanig, Keep reading [13:55] kushal, Yes doing that. :) [13:55] asraisingh, Have you searched the same question? [13:55] asraisingh, when I searched, I found https://stackoverflow.com/questions/14390519/whats-the-difference-between-b-and-b-in-vim [13:55] yes already did. but not able to understand [13:55] asraisingh, Point that I also never knew the difference. [13:55] ok, i have a read [13:55] asraisingh, read the answer from the link I gave [13:56] ok, thanks [13:56] ! [13:56] next [13:57] next [13:57] after doing man vim. What is the Ex mode ? which mode is better? [13:57] ! [13:57] santoshShaw, you will have to all the modes, just try and see. [13:57] ! [13:57] next [13:58] ok [13:58] my question has been answered already [13:58] next [13:58] kushal, I've something to ask about one python, so when should I ask [13:58] python project [13:58] zetathon__, after the session or before the session [13:58] on IRC channel only? [13:58] next [13:58] kushal: what's difference between :wq and :x command ! [13:58] zetathon__, or in the mailing list [13:58] My question is not related to vim rather it's bash scripting related from previous day. Can I ask it now? [13:58] ok [13:59] ! [13:59] iKshitij, noting that I know about, expect :x is one character less to type :) [13:59] arush, ask [14:00] next [14:00] kushal, Is working with hjkl is more preferable or with up-down-key-left-right key during editing in vim? [14:00] asraisingh, most of the vim users use hjkl [14:00] asdofindia, but again, personal choice [14:00] next [14:00] this error is popping: [14:01] ! [14:01] Downloading Packages: [14:01] (1/4): gpm-libs-1.20.7-9.fc24.x86_64.rpm 38 kB/s | 36 kB 00:00 [14:01] (2/4): vim-filesystem-8.0.617-1.fc25.x86_64.rpm 49 kB/s | 34 kB 00:00 [14:01] (3/4): vim-enhanced-8.0.617-1.fc25.x86_64.rpm 330 kB/s | 1.3 MB 00:03 [14:01] (4/4): vim-common-8.0.617-1.fc25.x86_64.rpm 541 kB/s | 6.6 MB 00:12 [14:01] --------------------------------------------------------------------------------------------------------- [14:01] Total 503 kB/s | 8.0 MB 00:16 [14:01] Running transaction check [14:01] Transaction check succeeded. [14:01] Running transaction test [14:01] The downloaded packages were saved in cache until the next successful transaction. [14:01] You can remove cached packages by executing 'dnf clean packages'. [14:01] Error: Transaction check error: [14:01] file /usr/share/man/man1/vim.1.gz from install of vim-common-2:8.0.617-1.fc25.x86_64 conflicts with file from package vim-minimal-2:7.4.1989-2.fc25.x86_64 [14:01] How to store a particular string with special characters, say "$" in an array variable such that when the string is printed its not interpolated? [14:01] Error Summary [14:01] ------------- [14:01] saikat_, eh [14:02] saikat_, please use a pastebin, like paste.fedoraproject.org [14:02] ok, was not aware of it [14:02] saikat_, that is a known error. [14:02] saikat_, first become root, sudo su - [14:02] tell when you are ready [14:02] I am root [14:02] asraisingh: I used to prefer nav key but when you​ start touch typing you don't want your finger to move to nav key. Hjkl seems easy :) [14:02] saikat_, then these two command one by one [14:03] dnf remove vim-minimal [14:03] dnf install vim sudo -y [14:03] asraisingh, https://www.flickr.com/photos/kent-chen/6825667892/ will give you more details :) [14:03] next [14:03] I do not have any question i just have a little request please send all the link for home work at the end of the session so i will only read those only. [14:03] kvy, Nope, we will not do that. [14:04] can i ask why? [14:04] ! [14:04] kvy, It is the duty of the participants to read the logs. [14:04] ! [14:04] i am reading [14:04] kvy, otherwise people may prefer to skip, which is okay, but you have to do the work. [14:04] We can not do more. [14:04] next [14:04] but still i confuse here are a lot of links [14:04] kushal, Can we change the character keys to move left,right,up down? [14:04] ! [14:04] im_mohsin, means? [14:05] kushal, getting this error on 1st command: Error: The operation would result in removing the following protected packages: sudo. [14:05] kvy: what you can do is write a script which filters the URLs alone from the log. [14:05] kushal, oh got it. [14:05] saikat_, not error, it is asking to press Y or N [14:05] press y [14:05] next [14:05] like instead of having 'h' to move left one character, Can we change? [14:05] Whats a visual mode? [14:05] ahole[m] no just the homework [14:05] im_mohsin, I don't know if that is possible [14:05] ahole[m], sounds interesting will try for sure [14:06] Out of context but where are these buffer editors used ? I know in servers we use them because they are light weight. [14:06] kushal, it does not say type y/n. pressed y, nothing happens [14:06] ok. Thanks. i thought it would good to arrange keys in sequence [14:06] saikat_, dnf remove sudo vim-minimal [14:06] what does it do? [14:07] next [14:07] Cyber_freak: you can use it day to day job also, depend on your preference [14:07] im_mohsin, Nope, there is a reason for those keys :) [14:07] dodococo, wait for that answer [14:07] ! [14:07] im_mohsin: I think you can edit vimrc to remap your keys [14:08] ! [14:08] ahole[m]: copying the logs in a txt file and just give a search like find in notepad will also do.In command line we can use grep for http [14:08] kushal, this error: [root@localhost ~]# dnf remove sudo vim-minimal [14:08] Dependencies resolved. [14:08] Error: The operation would result in removing the following protected packages: sudo. [14:08] [root@localhost ~]# ^C [14:08] Will get the pastebin after this session [14:08] stop flooding please. I cannot follow [14:08] soumam_: You'll have to run it everyday. [14:08] kushal, saikat_ it's the same on my fedora 26 beta VM. I think you can do sudo dnf remove vim-minimal without root, then become root and do the second line [14:08] dodococo: http://vimdoc.sourceforge.net/htmldoc/visual.html#Visual it will contain document around visual mode. [14:09] saikat_, you don't have to get the pastebin, just paste in paste.fedoraproject.org [14:09] saikat_, are you on F25? [14:09] yes [14:09] saikat_: use sudo dnf remove vim-minimal [14:09] saikat_: you did it wrong [14:09] ahole[m], that´s a 2 second job man :) [14:09] saikat_: you are removing sudo! :) [14:10] soumam_: I guess I am the lazy one. [14:10] iKshitij, yes, that will happen in this case [14:10] praveenkumar, same error with your command [14:11] dodococo, i look into it :) [14:11] saikat_: can you use pastebin and put what you tried and also error. [14:11] praveenkumar, okay [14:11] sounam, making a script and executing it would be a good learning curve if not done already [14:12] ! [14:12] dodococo, I will show in few minutes [14:12] next [14:12] This is regarding the change and delete. How can I press cw? When I press c the edit mode is turned on. [14:12] saikat_, and you also wait [14:12] ashwanig, it should not [14:13] kushal, yes. [14:13] ashwanig, press escape first [14:13] vipulgupta2048_ yes of course after i will learn python.I will do everything by script :) [14:13] ashwanig, Ah, you should be in the command mode. [14:13] you need to go in the command mode [14:13] Please stop talking about the other random things. [14:13] kushal, Sorry, my bad. [14:13] kushal :P [14:13] abhinavshirur, Good catch. [14:13] next [14:13] How to remove a PPA (repository) completely ? I have read the answers on forum but after doing ppa-purge, sources.list still shows the repositories. [14:13] kushal: sorry my bad. [14:14] ! [14:14] vipulgupta2048_: do you mean remove all PPA repo you have added? [14:15] vipulgupta2048_, sorry, I don't know about Ubuntu that well, can anyone else reply? [14:15] next [14:15] praveenkumar, kushal , here is the pastebin: https://paste.fedoraproject.org/paste/Ktm6fxENOC7xXofrqOul-Q [14:15] i am not able to use "J" and K" keys nor up and down arrows :( [14:15] anupamas, are you in the command mode? [14:15] anupamas hit escape [14:15] Sorry to late because final year result , which topic going on ? [14:15] roll call: Razy Kased [14:16] editor pavan [14:16] i am able to use h and l but not j and k [14:16] pavan: text editors mostly vi and vim [14:16] Dhairyya : thanks [14:16] the same goes with the arrows :( [14:16] sayan, No, Why would I do that. For installing Visual Studio a PPA was installed. I uninstalled vscode but the PPA still was left in the system and showing in sources.list in apt [14:16] anupamas, do you have more than one line in the file you edit? [14:16] anupamas, may be because you are in the first line. j and k to shift lines [14:17] yes schubisu [14:17] you need to have lines spread across the file, anupamas [14:17] ! [14:17] ! [14:17] vipulgupta2048_: it's possible, you would like to remove all the ppa. This is because it searches the PPA everytime when looking for packages [14:17] vipulgupta2048_: afaik, PPA are same as repo in Fedora [14:18] vipulgupta2048_: it's better maxking answers this, he uses Ubuntu [14:18] difficult to simultaneously follow the discussion here and also read from the log file! [14:18] saikat_: are you not able to install vim? [14:18] sayan, Yes [14:18] and also difficult to wait for ur turn [14:18] ! [14:18] 2 lines to be presise soumam_ schubisu dhairyya [14:18] meanwhile you can't do anything [14:19] kushal's network is down [14:19] anupamas: do 3-4 more [14:19] zetathon__, it's your [14:19] sayan, Last package not installing. [14:19] precise* [14:19] saikat_: login as root and remember don't log out of root until and unless I tell you [14:19] like :u is for undo, then what does :r do? [14:19] saikat_: I will tell you the steps one by one, okay? [14:19] saikat_: try man vim and see the first line. [14:19] sayan, yes, thank you, i am logged in as root [14:20] :r replaces and :u is for undo [14:20] Yes I know, In the software menu PPA installed by the users are shown separately. I just want to know the best way to remove them (one particularly), maxking [14:20] ! [14:20] sayan, first line says vim - Vi IMproved, a programmers text editor [14:20] samridhia, No its not replace [14:20] ! [14:20] its doing something else only [14:20] ! [14:20] saikat_: you have vim with the alias vi. [14:21] zetathon__, try that [14:21] :r is copy pasting the same stuff again [14:21] okay got it [14:21] next [14:21] like :u is for undo, then what does :r do? [14:21] saikat_: check pm [14:22] ahole[m], so do i need to upgrade it or what? when i try to open txt files, it opens with regular txt editors [14:22] I tried but, I dont know whats heppening [14:22] zetathon__ caps lock? [14:22] sayan, what is pm? [14:22] kushal, there was one line I typed long before [14:22] saikat_, personal message [14:22] zetathon__, that was out of turn. [14:22] but when I'm doing :r, that line is coming back? [14:22] ! [14:23] next [14:23] wrik003, my bad, sorry [14:23] batul told me to ask [14:23] and I asked [14:23] zetathon__, try this https://www.fprintf.net/vimCheatSheet.html [14:23] saikat_: No! As I have observed that some of the latest releases have vim per installed but you'll have to use [14:23] Vi filename.extension [14:23] to use vim. [14:23] No doubt [14:23] next [14:23] zetathon__, sorry, I have network lag, huge network lag this side [14:23] Also, how to get autocopletion for python in vim? [14:23] what's the difference between :e! and u they both do the same work ? [14:23] Till now my favorite has been the change case using ~ :D [14:23] kushal: I am taking the questions [14:23] autocompletion [14:24] zetathon__: can you tell your question again? [14:24] sayan, how to get autocompletion for python [14:24] sayan, go ahead then [14:24] in vim [14:24] zetathon__, we will see that later. [14:24] kushal, the cheat sheet is helpful! [14:24] anupamas, is j and k working? its also not working for me! not even my up/down cursor! only lateral movement is there [14:24] zetathon__: for that you need to install seperate plugin, let's not do that now [14:24] zetathon__: you need to configure and install plugin! [14:25] wrik003, Which cheat sheet? [14:25] ! [14:25] zetathon__: once you get acquainted with vim, then you can go ahead and install plugins [14:25] For the record http://summertraining.readthedocs.io/en/latest/vim.html [14:25] samridhia: can you repeat you questions, I seem to be have lost in logs? [14:25] sayan, I've have worked lill bit on vim before [14:25] ashwanig, https://www.fprintf.net/vimCheatSheet.html [14:25] but could never rectify this issue [14:26] zetathon__: well, in that case after the case we can talk about that [14:26] What's the difference between :e! and u they both work in the same way? [14:26] ! [14:26] sayan, which editor is best for python? [14:26] zetathon__: which ever suits you [14:26] I've tried lot [14:26] none of them suits me [14:27] nor sublime [14:27] nor IDLE [14:27] nor atom [14:27] I need autocompletion, and none of them supports completely [14:27] zetathon__, please stop [14:27] samridhia: both of :e & :u goes to a older state [14:27] zetathon__: try geany [14:27] vipulgupta2048_: /etc/apt/sources.list.d/ is the path where all.liats are [14:27] zetathon , please give chance to others to discuss [14:28] Thanks ahole[m] ;) [14:28] kushal, ok :p [14:28] zetathon__, next time you will be kicked out [14:28] *all lists are [14:28] samridhia: but there is a difference, :u does an undo [14:28] same goes to all others. [14:28] samridhia: where are with :e you go to an older state, that could be measured in time [14:28] kushal, this thing will not be repeated. Sorry for that. [14:29] samridhia: :e 5s will go 5 seconds before [14:29] sayan: got it perfectly! [14:29] or was that :ea, wait I am confused now :( [14:30] no it is :e! which takes back to the previous state without saving the new one [14:30] :e refreshes [14:30] or reload [14:30] /msg NickServ identify 123123kksk [14:30] samridhia: what vivek_ said [14:30] messifc, Now change the password [14:30] next [14:30] oops [14:30] next [14:30] kushal, I'm not able to use :e. Whenever using :e getting this error with some line number. E37: No write since last change (add ! to override) 7,29 All [14:30] soumam_, try increasing lines [14:31] asraisingh, Out of turn [14:31] Is there a auto indent feature in vim like sublime has ? [14:31] asraisingh, also save the file first. [14:31] kushal, ok [14:31] ! [14:31] Cyber_freak: yes. [14:32] kushal: no, it's asraisingh turn [14:32] ! [14:32] next [14:32] I read about it but couldn't understand [14:32] I know we are talking about editor Vim today, however I had a question about the FHS document, in my /media, I didn't see any other devices except floppy, why is that? [14:32] sayan, ah, I suddenly saw the message [14:32] asraisingh: :e not working for me too same comment [14:32] ! [14:33] I am putting the channel on mute. A few things now [14:33] People should not ask out of turn [14:34] or else I will remove voice from that person. [14:34] Returning back to normal model [14:35] rkased: ping at the end of the class [14:35] next [14:35] asraisingh, samridhia use :e! and not :e [14:35] I want to go to the n-th line, there are 2 ways as you told in previous logs. [14:35] sayan i also think so [14:35] :n and nG [14:35] kushal, what is Alt + a? [14:35] singh123: yes? [14:35] but nG does not work here [14:36] ! [14:37] singh123: how did you try the nG command? [14:37] zetathon__ according to me :e! and :e both have different work to do. [14:37] in command mode [14:37] singh123: did you use that with a :nG? [14:38] no [14:38] singh123: in command mode, to go to ling number 5 press 5G where n=5 [14:38] ! [14:38] that should work [14:38] next [14:38] kushal, what is Alt + a? [14:38] samridhia, what do you want to do? The thing that is in the log is about :e!, and I dont know what :e do [14:38] does [14:39] ! [14:39] sayan it is saying ambigious use of user defined command [14:39] ! [14:39] isn't there any way to render the logs in a more efficient way rather than just text, so that the links,tags and other stuffs are visible [14:39] sayan: it's just :n [14:39] :e is to edit at current position as its working for me [14:39] and G will take to the end of file [14:39] samridhia, zetathon__ , :e! working [14:40] theparadoxer02_: yes, but we will not work on it [14:40] asraisingh, samridhia :e is only used to re-edit if changes are made to the file outside of vim [14:40] im_mohsin: next time I am kicking you [14:40] ! [14:40] im_mohsin: you are asking question out of turn [14:40] next [14:41] sayan, i did not got you [14:41] ! [14:41] theparadoxer02_: you are asking of the dgplug logs right? [14:41] theparadoxer02_: it's possible but right now we just render the text file [14:41] next [14:41] pass ! My question is related to plugin, will ask that after today's session. [14:41] sayan, yes [14:41] iKshitij: cool [14:41] next [14:42] I use nano as a editor , would that be an issue ? [14:42] ! [14:42] i was reading documentation and when batul said next i accidentally sent it. Sorry sayan [14:45] ! [14:45] vipulgupta2048_: yes, totally works [14:45] if you are primarily using nano as your text editor [14:45] next [14:47] next [14:47] next [14:47] s,i and a-all three make insert mode active?what is the distinction? [14:48] Sorry my internet is acting up [14:48] I'm using Ubuntu 16.04, the $ doesn't work when I try to launch vim with it. It only works just by typing vim, then enter. Why is that? [14:48] apoorv28goel, read the log, all 3 of them have different meanings [14:49] that ques was not answered in the log [14:49] abhinavshirur, Agree with apoorv28goel [14:49] apoorv28goel: the are different task/modes [14:50] can you a little more ? [14:50] apoorv28goel: did you try to google? [14:50] i inserts at the cursor. a appends. google what s does [14:51] nope sorry [14:51] thank you [14:52] apoorv28goel: google, you will find them, there are minor differences, also search for o & O [14:52] next [14:52] When finding a word using vim, is there any way that the whole word gets highlighted? [14:52] okay [14:52] ashwanig: yes, you need to configure vim for that [14:52] ashwanig: vim has a configuration file called vimr [14:52] vimrc [14:53] s is just deleting the current position [14:53] My question, I didn't see my answer before you moved to the next questioner? [14:53] ! [14:54] anuGupta, no with s you find and replace text. eg: :s/foo/bar/g. G will replace all instance of foo [14:54] I have to leave the class in between. [14:54] rkased: sorry [14:54] no worries [14:55] sayan, Where is it located? [14:55] Not getting you,im_mohsin [14:55] it == vimrc file [14:55] ! [14:55] ashwanig, in your home directory [14:55] ashwanig: you need to create in the home dir, please google search [14:55] rkased: you don't need to type the $ [14:56] sounds good [14:56] anuGupta, check thiis link: http://vim.wikia.com/wiki/Search_and_replace [14:56] sayan, Ok got it :) [14:56] next [14:56] ! [14:56] sayan: What is the home work for today? [14:56] Raut: yes, I will tell at the last, it's related to vi itself [14:56] next [14:56] sayan, In using 'nG' command it gives error E464: Ambiguous use of user-defined command and what to do? [14:58] in ' n' command gives error E163: There is only one file to edit , why? [14:58] ani: hmm, are you typing nG or substituing n with a number? [14:59] like 5G, 6G etc [14:59] n with number [14:59] yes 5G [15:00] ani: I have no clue on this; ping me after the class we will discuss [15:00] sayan maybe there are not 5 lines in the file [15:00] ok [15:00] I was getting the same error [15:01] dhairyya: oh, but that works, you just go to the last line [15:01] can i? [15:01] vivek_: always, don't ask if you know answer [15:01] I am also getting the same error. [15:01] in normal mode, simply 4G will take you to 4th line [15:01] im_mohsin,I tried but its giving error. [15:01] but, if you press : before then you are in command mode [15:01] if you are in that mode, then you don't need G [15:02] sayan I tried in the command mode [15:02] just press :4 [15:02] it gives with any value having more line then i type in nG command [15:02] ! [15:02] next [15:02] I have to leave now, thanks for today's session. [15:02] naveejka: no issues, thank you [15:03] sayan, should I ask question? [15:04] sayan : I also need to leave, could you tell the home work? Sorry for asking out of turn. [15:04] Raut: can you check the logs later? [15:04] Oh it's working.thanks im_mohsin [15:04] it should be in the end [15:04] next [15:04] sayan, I have 2 questions. First one is, are some commands are different but with same function? and Second one is, Commands provided in this log https://dgplug.org/irclogs/kushal_vi_1stclass.log is enough or I have to cover maximum of the commands from cheatsheet (Link: https://www.fprintf.net/vimCheatSheet.html) [15:05] sayan : OK. Thanks for the session. [15:05] asraisingh: it depends on how flexible you want to be with vim :) [15:05] sure. try with :%s and simple :s anuGupta [15:05] both are different [15:05] Yeah [15:06] thanks im_mohsin, it works [15:06] ani, welcome :) [15:07] asraisingh: you can achieve same things multiple ways [15:07] asraisingh: you need to start using the editor, it's difficult in the beginning but then eases down [15:07] I need to leave. Thanks for the session [15:07] ! [15:08] https://static1.squarespace.com/static/537a9021e4b0dc8ed531ddef/t/579d9923e4fcb5403766d2ef/1469946184827/ [15:08] ! [15:08] sayan, thanks sayan [15:08] ^^ this explains [15:08] next [15:08] To copy a word we use , right? but say my cursor is not at the beginning of the word but somewhere at the middle, then it does not copy the word entirely (when I subsequently paste it) but from the position of the cursor till the end of the word. [15:09] sayan, my turn didnt come :( [15:11] wrik003_: nope [15:11] wrik003_: yiw [15:11] vivek_, sorry, what is this acronym for? [15:11] "i" is for the current word [15:11] yiw is the command you need [15:11] yank the current word [15:11] thank you so much for today's session, very helpful :) [15:11] sayan, i tried it multiple times [15:11] wrik003_: yw copies from current location [15:11] ! [15:12] sayan, yes but i think in the logs it was different. i'll check again. [15:12] wrik003_: yiw does the full word [15:12] wrik003_: what i said is the one you need [15:12] next [15:12] sayan, vivek_ thanks. [15:12] wrik003_: there is also "yaw" go check that one [15:12] vivek_, ok [15:12] next [15:12] sayan we are using a command line text editor because it doesnt uses mouse and saves our time or it has some other advantages too? [15:13] soumam_: it's faster that GUI [15:13] Sayan , Kushal. Thanks for session. But have to go, will read the logs. [15:13] vipulgupta2048_: no issues :) [15:13] log link plz? [15:13] soumam_: it saves time, moving around the file is lot easier [15:13] harshcrop, it's please not plz [15:13] harshcrop: what does plz mean? pizza? [15:13] ! [15:13] sayan: I need to go. Is there anything else in today's session ? and is there any homework for tomorrow ? [15:13] sayan, faster in terms of executing codes? [15:13] ! [15:13] soumam_: once you remove dependency from mouse you get to be faster [15:14] log link ? [15:14] because you don't need to move to navigate [15:14] ! [15:14] oh! [15:14] soumam_: people that why use h,j,k,l to navigate in vim [15:14] harshcrop, https://dgplug.org/irclogs/kushal_vi_1stclass.log [15:14] next [15:14] harshcrop, https://www.dgplug.org/irclogs/kushal_vi_1stclass.log [15:14] in command of ':s' gives error E33: No previous substitute regular expression [15:14] Thank you [15:14] ! [15:15] ani: you need to give the replacement args [15:15] ani: you have to specify which one search and to replace with what [15:15] and replace to what extent etc [15:15] ok [15:15] ! [15:15] ani: http://vim.wikia.com/wiki/Search_and_replace [15:15] ani: you will see it as :s/foo/bar/g [15:15] The line numbers disappears after I open it again. [15:15] next [15:15] :s/// [15:15] i googled how to indent in vim,got satisfactory result for insert mode but while trying commands like } seems nothing happening except the block getting highlighted ,could you suggest what i am missing ? [15:16] anuGupta: are you out of turn? [15:16] Sorry [15:16] deepika: to indent you can just use > and < [15:16] next [15:17] deepika: > indent, < for un-indent [15:17] sayad can it be live season as last years log? [15:17] singh123: the vim session? [15:17] okay,thanks ! [15:17] yes [15:18] singh123: we can have that, but once you know the basics then it's better [15:18] sayan, yes please. difficult to do both simultaneously. [15:18] ok got it, thanks [15:18] wrik003_: both as in? [15:18] singh123: the thing once you know stuffs then we can do a over view class [15:18] sayan, back and forth - irc & log [15:18] on the things you need the most [15:18] wrik003_: ok [15:19] wrik003_: right [15:19] next [15:19] sayan, :) [15:19] How can I cancel my order in the queue question. I just figured out the answer to my question. [15:19] rkased: I guess !! but I don't know if it happens now, the older bot used to do that [15:19] next [15:19] sorry, I have to leave, see you all tomorrow ;) [15:19] :set mouse=a , for navigating with mouse, if navigation using line numbers is complex, (reference- nG command) [15:20] see you [15:20] ! [15:20] ! [15:20] skarpy: is that your question? [15:20] next [15:20] next [15:20] sayan: I need to go. Is there anything else in today's session ? and is there any homework for tomorrow ? [15:20] like as you said vimrc is a configuration file to change the highlighting,there was also something vimrc.tiny ! what´s config file is that for?i also saw gvimrc which i guess is the config file for the gui version. [15:20] apoorv28goel: see you [15:20] any homework? [15:20] sayan: no, it's just something I want to share, becoz having problem was navigating, this ease it up [15:21] soumam_: I haven't heard about vimrc.tiny [15:21] For next class read: https://dgplug.org/irclogs/kushal_vi_2ndclass.log [15:21] next [15:21] sayan, > and < by default uses 8 spaces. How to change that? [15:21] ok no problem i think its updated so they have introduced something else, [15:22] im_mohsin: it's probably tab [15:22] ! [15:22] soumam_: I will look into it [15:22] see: how to assign tab to spaces [15:22] set tab=4 [15:22] vivek_, tab does not work command mode [15:22] sorry have to leave! will read the logs later . [15:23] Nice session got to go! Thanks, sayan :) [15:23] soumam_: http://vim.wikia.com/wiki/Indenting_source_code [15:23] next [15:23] next [15:23] How do I open my newly saved .txt file when I just close out of vim and back at the terminal? [15:23] next [15:23] '>' and '<' dont work if i press them once, but when i press them twice. Is it what's supposed to happen? [15:23] rkased: vim [15:24] excellent [15:24] messifc: does it indent [15:24] ? [15:24] yeah. [15:25] messifc: oh right [15:25] but it moves the word. What if i want to write another word after giving indentation? [15:25] It is taking time to indent. [15:25] messifc: you must be indenting a single line [15:25] messifc, I was trying :> and :< [15:25] messifc: >> << is use to indent a single line [15:25] rather the current line [15:26] okay thanx :) [15:26] messifc, it's thanks [15:26] messifc: it's thanks [15:26] please [15:26] mext [15:26] next [15:27] Wow, I won! [15:27] thanks :) [15:27] sayan, xD [15:27] Okay so I am given tomorrow homework, I will try to have a session for vim, hands-on [15:28] Sayan what is tomorrow haome work [15:28] mostly to discuss what all things you need and advanced classes [15:28] Again, tomorrow homework is https://dgplug.org/irclogs/kushal_vi_2ndclass.log [15:28] sayan: thanks for this amazing session :) [15:28] That's it for today? [15:28] ahole[m]: tomorrow [15:28] sayan, i admit you have extra energy [15:28] sayan, Enjoyed the session. Thank you. :) [15:28] thanks kaushal & sayan. [15:28] sayan, this is better. we can go through the log file beforehand. [15:29] ashwanig, And kushal also [15:29] wrik003_: an advanced class on how we use :) [15:29] Roll Call [15:29] Thanks, for the session :) [15:29] Anupama Shipurkar [15:29] Santosh Kumar Shaw [15:29] Shankar Jha [15:29] Messi Fc [15:29] Anu Kumari Gupta [15:29] Jason Braganza [15:29] Abhishek Singh [15:29] Wrik Bhadra [15:29] Kshithij Iyer [15:29] Vivek Anand [15:29] Akash pathak [15:29] Aniket uttam [15:29] Soumam Banerjee [15:29] kumar vipin yadav [15:29] Mayur khomane [15:29] Abhinav Shirur [15:29] Deepika Upadhyay [15:29] Priyanka Sharma [15:29] Bhavin Gandhi [15:29] Ranjeet kumar [15:29] Ashwani Kumar Gupta [15:29] deep [15:29] pooja kumari singh [15:29] Ravindra Lakal [15:29] Razy Kased [15:29] Ishank Gupta [15:30] Amarjeet singh [15:30] Avik Mukherjee [15:30] Devesh Verma [15:30] Saikat Dey [15:30] Nishanta Sarma [15:30] Chiranjeev Gupta ----END CLASS----