What Every Vi User Should Know about Vim

Slides:



Advertisements
Similar presentations
Microsoft Word – Lesson 1
Advertisements

Editing with vi Or more fun than you thought you’d have without a mouse Prof. Chris GauthierDickey.
Microsoft Word Review.
VIM: The basics Tang Wai-Chung, Matthew (MaFai) 29/12/2006.
CS 497C – Introduction to UNIX Lecture 10: The vi/vim Editor Chin-Chih Chang
Office 2003 Introductory Concepts and Techniques M i c r o s o f t Word Project 1 Creating and Editing a Word Document.
Creating, Formatting, and Editing a Word Document with a Picture
Lesson 1: Understanding Word
Module 3 Productivity Programs Common Features and Commands Microsoft Office 2007.
Word Processing basics
CSCI 330 T HE UNIX S YSTEM Editing files. E DITOR C ONCEPTS Editing a file is to modify the content of a file Text editor: Enter and modify text in a.
Source code indexer. What does it do?  Indexes source code for fast lookups of methods, variables, structs, macros, …  But LXR does this… Ctags can.
Microsoft Office 2007 Word Chapter 1 Creating and Editing a Word Document.
Lesson 7: Creating and Editing Business Letters. 2 Learning Objectives After studying this lesson, you will be able to:  Type a professional business.
Return to the Word 2007 web page Lesson 2: Creating and Editing Business Letters.
Word Lesson 2 Basic Editing
Microsoft Word 2000 Presentation 2 Microsoft Word Topics  Tools –Spelling/Grammar Check –Thesaurus –AutoCorrect –Word Count –Change Case –Background.
1 Introduction to Word Chapter 1 Lecture Outline.
Quick Reference notes  Part of the Microsoft® Office Fluent user interface, the ribbon is the rectangular region across the top of the document window.
Office 2003 Introductory Concepts and Techniques M i c r o s o f t Word Project 1 Creating and Editing a Word Document.
Introduction to Vim Robbie CSCI2100 Data Structures Tutorial 3.
© 2010 South-Western / Cengage Learning Century 21 Keyboarding  Cycle 1  Office Features 1.
1 Lesson 13 Editing and Formatting documents Computer Literacy BASICS: A Comprehensive Guide to IC 3, 4 th Edition Morrison / Wells.
McGraw-Hill/Irwin The Interactive Computing Series © 2002 The McGraw-Hill Companies, Inc. All rights reserved. Microsoft Word 2002 Lesson 3 Advanced Editing.
Text editors Why should I use an editor ? It is very important to able to use at least one text mode editor a text mode editor is so useful on remote machines.
Tony Kombol.  Why text edit?  Many programs and features require configuration ▪ Configuration is kept in files ▪ Usually in the /etc directory  Changes.
Microsoft Word Level 1 Michael Carco. Word Level 1 Agenda  Word Basics  Navigating in a Document  Inserting and Modifying Text  Creating and Modifying.
Word Lesson 2 Basic Editing
1 Lesson 8 Editing and Formatting Documents Computer Literacy BASICS: A Comprehensive Guide to IC 3, 3 rd Edition Morrison / Wells.
Introduction to Microsoft Word Introduction to toolbars and buttons.
1. Chapter 1 Creating, Printing, and Editing Documents.
VIM Advanced Why VIM? Easy to study Much easy to use Very easy to find from host You can defined it for yourself You can save.
Proofing Documents Lesson 9 #1.09.
CHAPTER 5 Introduction to Word Processing. OBJECTIVES 1.Define common terms related to word processing 2.Create, format, edit, save, and print Microsoft.
Pasewark & Pasewark 1 Word Lesson 2 Basic Editing Microsoft Office 2007: Introductory.
1. Using word you can create the document and edit them later, as and when required,by adding more text, modifying the existing text, deleting/moving.
Microsoft Word Terms.
Understanding Word Vocabulary
1 Word Lesson 2 Basic Editing Microsoft Office 2010 Introductory Pasewark & Pasewark.
Word processing is the software package that enables you to create,edit, print and save documents for future retrieval reference. creating a document.
CHAPTER 1 & 2 – MICROSOFT WORD Sravanthi Lakkimsetty April 11, 2016.
Purdue Linux Users Group Presents Linux 201: Session 1 Everything you ever wanted to do in VIM Thor Smith.
Advanced Vim (Vi Improved). Announcement Managements requests that all the Emacs chauvinist in the audience refrain from arguing with the Vim chauvinist.
Vim basics Vi IMproved.
Using Vi(m) This presentation on using the Vi(m) editor will cover:
Unit 3, Lesson 2 Enhancing PowerPoint Presentations
Word Processing Computer Technology.
Microsoft Excel A Spreadsheet Program.
Guide To UNIX Using Linux Third Edition
Word Lesson 2 Basic Editing
MYGRAPHICSLAB: ADOBE INDESIGN CS6
Vi Introduction Tony Kombol.
Technical University of Kosice
Program Development with Vim
VIM - Vi IMproved Bryce Handerson
Text Editors Vim (Chapter 6) Emacs (Chapter 7)
JEdit.
Introduction to Word Chapter 1
Lesson 3: Find and Replace Tools
Microsoft Excel 2007 – Level 1
Lesson 13 Editing and Formatting documents
Linux Operations and Administration
1 Word Processing Part I.
Grauer and Barber Series Microsoft Word Chapter One
CSCI The UNIX System Editing files
Mu Editor – New User Cheat Sheet – CircuitPython Mode
Mu Editor – New User Cheat Sheet – CircuitPython Mode
Presentation transcript:

What Every Vi User Should Know about Vim 7/23/2018 InterACT 2007

Getting Started Microsoft Windows users – Get Vim from http://www.vim.org Linux users, check to see that the advanced version of the Vim package is installed. Bleeding edge user, get the source at http://www.vim.org 7/23/2018 InterACT 2007

Unix Vim Starts in Vi mode unless you tell it different Create a .vimrc file to turn on many of Vim’s nicer features. $ touch ~/.vimrc Starting Vim with it’s own window. $ gvim {file} 7/23/2018 InterACT 2007

First Differences The undo (u) command handles multiple levels. (Use CTRL-R to redo a command.) Vim has a help system that is mostly complete and actually useful: :help 7/23/2018 InterACT 2007

Help System Normal commands Help for options Insert mode commands :help d :help CTRL-D :help :s Help for options :help 'sw' Insert mode commands :help i_CTRL-D Help for visual mode commands :help v_d 7/23/2018 InterACT 2007

Splitting Windows Open a new window :split {file} Close a window :q ZZ Up / Down windows CTRL-Wj CTRL-Wk 7/23/2018 InterACT 2007

Vertical Windows Vertical Spliting :vsplit {file} Any command which opens a window can be preceeded by: :vertical Left / Right windows CTRL-Wh CTRL-Wl 7/23/2018 InterACT 2007

Building Programs Start a build :make Current, next, previous error :cc :cn :cp Open a window with the list of errors :copen 7/23/2018 InterACT 2007

Searching Options Highlight searches :set hlsearch Turn it off (for now) :nohl Incremental searches :copen 7/23/2018 InterACT 2007

Visual Mode Character visual mode v (lower case) Line visual mode V (upper case) Block visual mode Ctrl-V 7/23/2018 InterACT 2007

Indenting Setting the indent size :set sw=4 Turning on C Style Indentation :set cindent Indenting a block of text (from { to } ) =% v%= 7/23/2018 InterACT 2007

Spelling Turn on spell checking :set spell Word correction z= 7/23/2018 InterACT 2007

Tabs Change tabs into spaces (on insert) :set expandtabs Changing tabs into spaces (in a file) 1g!Gexpand Do not turn expandtabs for Makefiles. 7/23/2018 InterACT 2007

Seeing Tabs Seeing the invisible :set list Seeing normal :set nolist 7/23/2018 InterACT 2007

Autocommands In your .vimrc :autocmd FileType *.[ch] \ set cindent,expandtabs 7/23/2018 InterACT 2007

Keyboard Macros Starting a keyboard macro qa Ending a macro q Executing macro @a 7/23/2018 InterACT 2007

Abbreviations and Mappings Defining an abbreviation :define #i #include Defining a keyboard mapping :map <F7> =% 7/23/2018 InterACT 2007