annotate runtime/tutor/tutor.da.utf-8 @ 20833:ca13ee9c6f8a

Added tag v8.2.0968 for changeset 045442aa392be8dc5a1d9539aaa2a30b82aeace2
author Bram Moolenaar <Bram@vim.org>
date Sat, 13 Jun 2020 13:30:05 +0200
parents 314694a2e74a
children e69e7133c9cf
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
14298
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
1 ===============================================================================
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
2 = V e l k o m m e n t i l V I M - v e j l e d n i n g e n - Version 1.7 =
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
3 ===============================================================================
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
4
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
5 Vim er en meget kraftfuld editor med mange kommandoer, for mange til
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
6 at forklare i en vejledning som denne. Vejledningen er designet til at
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
7 beskrive nok af kommandoerne til at du vil være i stand til let at bruge
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
8 Vim som en alsidig editor.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
9
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
10 Det tager cirka 25-30 minutter at fuldføre vejledningen,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
11 afhængig af hvor meget tid der bruges på at eksperimentere.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
12
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
13 VÆR OPMÆRKSOM PÅ AT:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
14 Kommandoerne i lektionerne ændre teksten. Opret en kopi af filen
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
15 til at øve på (hvis du startede "vimtutor", så er det allerede en kopi).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
16
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
17 Det er vigtigt at huske på at vejledningen er sat op til at lære ved at
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
18 bruge. Det betyder at du skal udføre kommandoerne for at lære at bruge
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
19 dem ordentligt. Læser du kun teksten, så glemmer du kommandoerne!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
20
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
21 Sørg for at din Caps-Lock-tast IKKE er aktiveret og tryk
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
22 på j-tasten nok gange til at flytte markøren så lektion 1.1
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
23 fylder hele skærmen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
24 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
25 Lektion 1.1: FLYT MARKØREN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
26
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
27
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
28 ** Tryk på h-,j-,k-,l-tasterne som vist, for at flytte markøren. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
29 ^
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
30 k Fif: H-tasten er til venstre og flytter til venstre.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
31 < h l > L-tasten er til højre og flytter til højre.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
32 j J-tasten ligner en ned-pil.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
33 v
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
34 1. Flyt markøren rundt på skærmen indtil du er fortrolig med det.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
35
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
36 2. Hold ned-tasten (j) nede, indtil den gentager.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
37 Nu ved du hvordan du flytter til den næste lektion.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
38
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
39 3. Brug ned-tasten til at flytte til lektion 1.2.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
40
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
41 BEMÆRK: Hvis du nogensinde bliver i tvivl om noget du skrev, så tryk på <ESC>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
42 for at stille dig i normal tilstand. Skriv så kommandoen igen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
43
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
44 BEMÆRK: Piletasterne bør også virke. Men med hjkl kan du flytte rundt
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
45 meget hurtigere, når du har vænnet dig til det. Seriøst!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
46
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
47 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
48 Lektion 1.2: AFSLUT VIM
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
49
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
50
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
51 !! BEMÆRK: Læs hele lektionen, inden trinnene nedenfor udføres!!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
52
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
53 1. Tryk på <ESC>-tasten (for at være sikker på, at du er i normal tilstand).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
54
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
55 2. Skriv: :q! <ENTER>.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
56 Det afslutter editoren, hvorved ændringer som du har foretaget forkastes.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
57
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
58 3. Vend tilbage hertil ved at udføre kommandoen som fik dig ind i
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
59 vejledningen. Det var muligvis: vimtutor <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
60
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
61 4. Hvis du har lært trinnene udenad og er klar, så udfør trin
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
62 1 til 3 for at afslutte og komme ind i editoren igen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
63
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
64 BEMÆRK: :q! <ENTER> forkaster ændringer som du har foretaget. Om få lektioner
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
65 vil du lære at gemme ændringerne til en fil.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
66
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
67 5. Flyt markøren ned til lektion 1.3.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
68
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
69
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
70 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
71 Lektion 1.3: TEKSTREDIGERING - SLET
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
72
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
73
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
74 ** Tryk på x for at slette tegnet som markøren er ovenpå. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
75
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
76 1. Flyt markøren ned til linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
77
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
78 2. Ret fejlene ved at flytte markøren indtil den er ovenpå
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
79 tegnet som skal slettes.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
80
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
81 3. Tryk på x-tasten for at slette det uønskede tegn.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
82
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
83 4. Gentag trin 2 til 4 indtil sætningen er korrekt.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
84
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
85 ---> Kkoen sprangg ovverr måånen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
86
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
87 5. Gå videre til lektion 1.4, nu hvor linjen er korrekt.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
88
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
89 BEMÆRK: Efterhånden som du gennemgår vejledningen, så lær det ikke udenad,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
90 lær det ved at gøre det.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
91
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
92
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
93 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
94 Lektion 1.4: TEKSTREDIGERING - INDSÆT
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
95
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
96
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
97 ** Tryk på i for at indsætte tekst. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
98
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
99 1. Flyt markøren ned til den første linje med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
100
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
101 2. For at gøre den første linje magen til den anden, skal markøren flyttes
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
102 ovenpå det først tegn EFTER der hvor teksten skal indsættes.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
103
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
104 3. Tryk på i og skriv de nødvendige tilføjelser.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
105
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
106 4. Efterhånden som hver fejl rettes, så tryk på <ESC> for at vende tilbage
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
107 til normal tilstand. Gentag trin 2 til 4 for at rette sætningen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
108
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
109 ---> Der mangler tekst dene .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
110 ---> Der mangler noget tekst på denne linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
111
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
112 5. Når du fortrolig med at indsætte tekst, så flyt til lektion 1.5.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
113
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
114
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
115
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
116 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
117 Lektion 1.5: TEKSTREDIGERING - VEDHÆFT
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
118
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
119
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
120 ** Tryk på A for at vedhæfte tekst. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
121
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
122 1. Flyt markøren ned til den første linje med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
123 Det er lige meget hvilket tegn markøren er på, på linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
124
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
125 2. Tryk på A og skriv de nødvendige tilføjelser.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
126
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
127 3. Tryk på <ESC> når teksten er blevet vedhæftet for at vende tilbage til normal tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
128
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
129 4. Flyt markøren til den anden linje med ---> og gentag
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
130 trin 2 og 3 for at rette sætningen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
131
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
132 ---> Der mangler noget tekst på den
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
133 Der mangler noget tekst på denne linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
134 ---> Der mangler også noget tek
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
135 Der mangler også noget tekst her.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
136
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
137 5. Når du er fortrolig med at vedhæfte tekst, så flyt til lektion 1.6.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
138
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
139 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
140 Lektion 1.6: REDIGER EN FIL
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
141
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
142 ** Brug :wq til at gemme en fil og afslutte. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
143
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
144 !! BEMÆRK: Læs hele lektionen, inden trinnene nedenfor udføres!!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
145
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
146 1. Afslut vejledningen som du gjorde i lektion 1.2: :q!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
147 Eller gør følgende i en anden terminal, hvis du har adgang til en.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
148
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
149 2. Skriv denne kommando i skalprompten: vim tutor <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
150 'vim' er kommandoen til at starte Vim-editoren, 'tutor' er navnet på
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
151 filen som du vil redigere. Brug en fil som kan ændres.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
152
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
153 3. Indsæt og slet tekst, som du lærte vi de forrige lektioner.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
154
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
155 4. Gem filen med ændringer og afslut Vim med: :wq <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
156
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
157 5. Hvis du afsluttede vimtutor i trin 1, så genstart vimtutor og flyt ned
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
158 til følgende opsummering.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
159
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
160 6. Udfør trinnene ovenfor, når du har læst og forstået dem.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
161
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
162 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
163 Lektion 1 OPSUMMERING
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
164
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
165
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
166 1. Markøren flyttes enten med piletasterne eller hjkl-tasterne.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
167 h (venstre) j (ned) k (op) l (højre)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
168
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
169 2. Vim startes fra skalprompten, ved at skrive: vim FILNAVN <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
170
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
171 3. Vim afsluttes, ved at skrive: <ESC> :q! <ENTER> for at forkaste alle ændringer.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
172 ELLER, ved at skrive: <ESC> :wq <ENTER> for at gemme ændringerne.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
173
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
174 4. Slet tegn ved markøren, ved at skrive: x
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
175
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
176 5. Indsæt eller vedhæft tekst, ved at skrive:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
177 i skriv indsat tekst <ESC> indsæt inden markøren
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
178 A skriv vedhæftet tekst <ESC> vedhæft efter linjen
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
179
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
180 BEMÆRK: Når der trykkes på <ESC>, så stilles du i normal tilstand eller også
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
181 annulleres en uønsket og delvist fuldført kommando.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
182
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
183 Fortsæt nu med lektion 2.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
184
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
185 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
186 Lektion 2.1: SLETTEKOMMANDOER
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
187
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
188
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
189 ** Skriv dw for at slette et ord. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
190
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
191 1. Tryk på <ESC> for at være sikker på, at du er i normal tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
192
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
193 2. Flyt markøren ned til linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
194
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
195 3. Flyt markøren til begyndelsen af et ord som skal slettes.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
196
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
197 4. Skriv dw for at få ordet til at forsvinde.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
198
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
199 BEMÆRK: Bogstavet d vises på den sidste linje på den skærm du skrev
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
200 det på. Vim venter på at du skriver w . Hvis du ser et andet tegn
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
201 end d , så skrev du forkert; tryk på <ESC> og start forfra.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
202
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
203 ---> Der er regnorm nogle ord som sjovt ikke hører til papir i sætningen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
204
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
205 5. Gentag trin 3 og 4 indtil sætningen er korrekt og gå til lektion 2.2.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
206
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
207
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
208 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
209 Lektion 2.2: FLERE SLETTEKOMMANDOER
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
210
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
211
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
212 ** Skriv d$ for at slette til slutningen af linjen. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
213
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
214 1. Tryk på <ESC> for at være sikker på, at du er i normal tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
215
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
216 2. Flyt markøren ned til linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
217
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
218 3. Flyt markøren til slutningen af den rette linje (EFTER det første . ).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
219
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
220 4. Skriv d$ for at slette til slutningen af linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
221
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
222 ---> Nogen skrev slutningen af linjen to gange. slutningen af linjen to gange.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
223
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
224
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
225 5. Flyt videre til lektion 2.3 for at forstå hvad der sker.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
226
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
227
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
228
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
229
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
230
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
231 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
232 Lektion 2.3: OM OPERATORER OG BEVÆGELSER
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
233
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
234
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
235 Mange kommandoer som ændre tekst skabes fra en operator og en bevægelse.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
236 Formatet til en slettekommando med sletteoperatoren d er som følger:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
237
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
238 d bevægelse
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
239
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
240 Hvor:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
241 d - er sletteoperatoren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
242 bevægelse - er hvad operatoren skal arbejde på (oplistet nedenfor).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
243
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
244 En kort liste over bevægelser:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
245 w - indtil begyndelsen af det næste ord, EKSKLUSIV dets første tegn.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
246 e - til slutningen af det nuværende ord, INKLUSIV det sidste tegn.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
247 $ - til slutningen af linjen, INKLUSIV det sidste tegn.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
248
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
249 Så når der skrives de så slettes der fra markøren til slutningen af ordet.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
250
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
251 BEMÆRK: Når kun bevægelsen trykkes i normal tilstand, uden en operator,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
252 så flyttes markøren som angivet.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
253
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
254 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
255 Lektion 2.4: BRUG TÆLLER TIL EN BEVÆGELSE
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
256
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
257
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
258 ** Når der skrives et nummer inden en bevægelse, så gentages den det antal gange. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
259
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
260 1. Flyt markøren ned til begyndelsen af linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
261
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
262 2. Skriv 2w for at flytte markøren fremad to ord.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
263
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
264 3. Skriv 3e for at flytte markøren fremad til slutningen af det tredje ord.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
265
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
266 4. Skriv 0 (nul) for at flytte til begyndelsen af linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
267
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
268 5. Gentag trin 2 og 3 med forskellige numre.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
269
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
270 ---> Dette er blot en linje med ord som du kan flytte rundt i.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
271
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
272 6. Flyt videre til lektion 2.5.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
273
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
274
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
275
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
276
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
277 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
278 Lektion 2.5: BRUG TÆLLER TIL AT SLETTE FLERE
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
279
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
280
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
281 ** Når der skrives et nummer med en operator, så gentages den det antal gange. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
282
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
283 I kombinationen med sletteoperatoren og en bevægelse nævnt ovenfor kan du
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
284 indsætte en tæller inden bevægelsen for at slette flere:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
285 d nummer bevægelse
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
286
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
287 1. Flyt markøren til det første ord MED STORT på linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
288
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
289 2. Skriv d2w for at slette de to ord MED STORT
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
290
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
291 3. Gentag trin 1 og 2 med en anden tæller for at slette de efterfølgende
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
292 ord MED STORT med én kommando
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
293
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
294 ---> denne ABC DE linje FGHI JK LMN OP med ord er Q RS TUV renset.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
295
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
296
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
297
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
298
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
299
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
300 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
301 Lektion 2.6: ARBEJD PÅ LINJER
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
302
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
303
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
304 ** Skriv dd for at slette en hel linje. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
305
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
306 Pga. at sletning af linjer bruges så ofte, så besluttede designerne af Vi
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
307 at det ville være lettere bare at skrive to d'er for at slette en linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
308
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
309 1. Flyt markøren til den anden linje i frasen nedenfor.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
310 2. Skriv dd for at slette linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
311 3. Flyt nu til den fjerde linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
312 4. Skriv 2dd for at slette to linjer.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
313
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
314 ---> 1) Roser er røde,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
315 ---> 2) Mudder er sjovt,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
316 ---> 3) Violer er blå,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
317 ---> 4) Jeg har en scooter,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
318 ---> 5) Ure viser tiden,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
319 ---> 6) Sukker er sødt
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
320 ---> 7) Og du er lige så.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
321
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
322
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
323 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
324 Lektion 2.7: FORTRYD-KOMMANDOEN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
325
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
326
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
327 ** Tryk på u for at fortryde de sidste kommandoer, U for at rette en hel linje. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
328
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
329 1. Flyt markøren ned til linjen med ---> og placer den på
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
330 den første fejl.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
331 2. Skriv x for at slette det første uønskede tegn.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
332 3. Skriv nu u for at fortryde den sidste kommando der blev udført.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
333 4. Ret denne gang alle fejlene på linjen med x-kommadoen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
334 5. Skriv nu et stort U for at få linjen tilbage til dens oprindelige tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
335 6. Skriv nu u nogle få gange for at fortryde U'et og forudgående kommandoer.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
336 7. Skriv nu CTRL-R (hold CTRL-tasten nede mens der trykkes på R) nogle få gange
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
337 for at omgøre kommandoerne (fortryd fortrydelserne).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
338
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
339 ---> Rett fejlene ppå liinjen og errstat dem meed fortryd.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
340
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
341 8. Det er meget nyttige kommandoer. Flyt nu til lektion 2 opsummering.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
342
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
343
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
344
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
345
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
346 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
347 Lektion 2 OPSUMMERING
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
348
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
349
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
350 1. Slet fra markøren op til det næste ord, ved at skrive: dw
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
351 2. Slet fra markøren til slutningen af en linje, ved at skrive: d$
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
352 3. Slet en hel linje, ved at skrive: dd
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
353
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
354 4. Gentag en bevægelse ved at vedhæfte et nummer i begyndelsen: 2w
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
355 5. Formatet til en ændr-kommando er:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
356 operator [nummer] bevægelse
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
357 hvor:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
358 operator - er hvad der skal gøres, såsom d for at slette
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
359 [nummer] - er en valgfri tæller til at gentage bevægelsen
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
360 bevægelse - flytter over teksten som der skal arbejde på, såsom w (ord),
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
361 $ (til slutningen af linjen), osv.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
362
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
363 6. Flyt til begyndelsen af linjen med et nul: 0
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
364
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
365 7. Fortryd tidligere handlinger, ved at skrive: u (lille u)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
366 Fortryd alle ændringerne på en linje, ved at skrive: U (stort U)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
367 Fortryd fortrydelserne, ved at skrive: CTRL-R
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
368
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
369 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
370 Lektion 3.1: PUT-INDSÆTTE-KOMMANDOEN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
371
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
372
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
373 ** Skriv p for at put-indsætte tidligere slettede tekst efter markøren. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
374
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
375 1. Flyt markøren ned til den første linje med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
376
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
377 2. Skriv dd for at slette linjen og gemme den i et Vim-register.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
378
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
379 3. Flyt markøren til c)-linjen, OVER hvor den slettede linje skal være.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
380
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
381 4. Skriv p for at put-indsætte linjen nedenunder markøren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
382
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
383 5. Gentag trin 2 til 4 for at put-indsætte alle linjerne i den rigtige rækkefølge.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
384
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
385 ---> d) Kan du lære lige så?
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
386 ---> b) Violer er blå,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
387 ---> c) Intelligens skal læres,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
388 ---> a) Roser er røde,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
389
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
390
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
391
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
392 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
393 Lektion 3.2: ERSTAT-KOMMANDOEN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
394
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
395
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
396 ** Skriv rx for at erstatte tegnet ved markøren med x . **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
397
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
398 1. Flyt markøren ned til den første linje med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
399
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
400 2. Flyt markøren så den er ovenpå den første fejl.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
401
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
402 3. Skriv r og så tegnet som skal være der.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
403
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
404 4. Gentag trin 2 og 3 indtil den første linje er magen til den anden.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
405
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
406 ---> Def var nohen der trukkede på de forkerge taster, da linjem blev skrevet!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
407 ---> Der var nogen der trykkede på de forkerte taster, da linjen blev skrevet!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
408
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
409 5. Flyt nu videre til lektion 3.3.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
410
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
411 BEMÆRK: Husk på at du skal lære ved at gøre det, ikke ved at lære det udenad.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
412
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
413
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
414
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
415 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
416 Lektion 3.3: ÆNDRINGSOPERATOREN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
417
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
418
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
419 ** Ændr indtil slutningen af et ord, ved at skrive ce . **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
420
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
421 1. Flyt markøren ned til den første linje med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
422
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
423 2. Placer markøren på k'et i likibj.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
424
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
425 3. Skriv ce og det korrekte ord (i dette tilfælde skrives njen ).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
426
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
427 4. Tryk på <ESC> og flyt til det næste tegn der skal ændres.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
428
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
429 5. Gentag trin 3 og 4 indtil den første sætning er magen til den anden.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
430
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
431 ---> Likibj har nogle få ndo som vnes ændres vrf ændringsoperatoren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
432 ---> Linjen har nogle få ord som skal ændres med ændringsoperatoren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
433
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
434 Bemærk at ce sletter ordet og stiller dig i indsæt-tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
435
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
436
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
437
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
438 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
439 Lektion 3.4: FLERE ÆNDRINGER MED c
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
440
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
441
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
442 ** ÆNDRINGSOPERATOREN bruges med de samme bevægelser som slet. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
443
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
444 1. Ændringsoperatoren virker på samme måde som slet. Formatet er:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
445
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
446 c [nummer] bevægelse
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
447
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
448 2. Bevægelserne er de samme, såsom w (ord) og $ (slutningen af linjen).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
449
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
450 3. Flyt ned til den første linje med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
451
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
452 4. Flyt markøren til den første fejl.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
453
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
454 5. Skriv c$ og skriv resten af linjen som den anden linje og tryk på <ESC>.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
455
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
456 ---> Slutningen af linjen har brug for lidt hjælp til at blive ligesom den anden.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
457 ---> Slutningen af linjen skal rettes med c$-kommandoen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
458
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
459 BEMÆRK: Du kan bruge backspace-tasten til at rette fejl når du skriver.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
460
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
461 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
462 Lektion 3 OPSUMMERING
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
463
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
464
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
465 1. Put-indsæt tekst tilbage som lige er blevet slettet, ved at skrive p .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
466 Det put-indsætter den slettede tekst EFTER markøren (hvis en linje blev
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
467 slettet, så vil den være på linjen nedenunder markøren).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
468
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
469 2. Erstat tegnet under markøren, ved at skrive r og så
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
470 tegnet som du vil have der.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
471
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
472 3. Ændringsoperatoren giver dig mulighed for at ændre fra markøren til hvor
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
473 bevægelsen tager dig hen. Skriv f.eks. ce for at ændre fra markøren til
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
474 slutningen af ordet, c$ for at ændre til slutningen af en linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
475
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
476 4. Formatet til at ændre er:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
477
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
478 c [nummer] bevægelse
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
479
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
480 Gå nu videre til den næste lektion.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
481
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
482
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
483
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
484 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
485 Lektion 4.1: MARKØRPLACERING OG FILSTATUS
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
486
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
487 ** Skriv CTRL-G for at vise din placering i filen og filstatussen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
488 Skriv G for at flytte til en linje i filen. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
489
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
490 BEMÆRK: Læs hele lektionen, inden trinnene udføres!!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
491
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
492 1. Hold Ctrl-tasten nede og tryk på g . Vi kalder det CTRL-G.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
493 Der vises en meddelelse nederst på siden med filnavnet og
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
494 placeringen i filen. Husk linjenummeret til trin 3.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
495
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
496 BEMÆRK: Du ser muligvis markørplaceringen nederst i højre hjørne af skærmen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
497 Det sker når 'ruler'-valgmuligheden er sat (se :help 'ruler' )
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
498
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
499 2. Tryk på G for at flytte dig nederst i filen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
500 Skriv gg for at flytte dig øverst i filen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
501
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
502 3. Skriv nummeret på den linje du var på, og så G . Det
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
503 returnerer dig til den linje du var på da du første trykkede på CTRL-G.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
504
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
505 4. Hvis du føler dig klar til at gøre det, så udføre trin 1 til 3.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
506
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
507 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
508 Lektion 4.2: SØG-KOMMANDOEN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
509
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
510
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
511 ** Skriv / efterfulgt af en frase for at søge efter frasen. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
512
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
513 1. I normal tilstand, skriv /-tegnet . Bemærk at det og markøren
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
514 vises i bunden af skærmen som med :-kommandoen .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
515
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
516 2. Skriv nu 'feeejjl' <ENTER>. Det er ordet du vil søge efter.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
517
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
518 3. Søg efter den samme frase igen, ved blot at skrive n .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
519 Søg efter den samme frase i den anden retning, ved at skrive N .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
520
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
521 4. Søg efter en frase i den modsatte retning, ved at bruge ? i stedet for / .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
522
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
523 5. Gå tilbage hvor du kom fra, ved at trykke på CTRL-O (Hold Ctrl nede mens
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
524 der trykkes på bogstavet o). Gentag for at gå længere tilbage. CTRL-I går fremad.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
525
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
526 ---> "feeejjl" er den forkerte måde at stave til fejl; feeejjl er en fejl.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
527 BEMÆRK: Når søgningen når slutningen af filen, så fortsætter den ved
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
528 begyndelsen, men mindre 'wrapscan'-valgmuligheden er blevet slået fra.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
529
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
530 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
531 Lektion 4.3: SØG EFTER MODSVARENDE PARENTESER
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
532
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
533
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
534 ** Skriv % for at finde en modsvarende ),], eller } . **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
535
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
536 1. Placer markøren på (, [, eller { på linjen nedenfor med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
537
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
538 2. Skriv nu %-tegnet .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
539
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
540 3. Markøren flytter til den modsvarende parentes eller klamme.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
541
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
542 4. Skriv % for at flytte markøren til den anden modsvarende klamme.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
543
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
544 5. Flyt markøren til en anden (,),[,],{ eller } og se hvad % gør.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
545
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
546 ---> Dette ( er en testlinje med ('er, ['er ] og {'er }. ))
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
547
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
548
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
549 BEMÆRK: Det er meget nyttigt ved fejlretning af et program som mangler
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
550 modsvarende parenteser!
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
551
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
552
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
553 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
554 Lektion 4.4: UDSKIFT-KOMMANDOEN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
555
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
556
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
557 ** Skriv :s/gammel/ny/g for at udskifte 'gammel' med 'ny'. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
558
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
559 1. Flyt markøren ned til linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
560
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
561 2. Skriv :s/dett/det <ENTER> . Bemærk at kommandoen kun ændre den
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
562 første forekomst af "dett" på linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
563
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
564 3. Skriv nu :s/dett/det/g . Når g-flaget tilføjes, så udskiftes der
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
565 globalt på linjen, altså ændre alle forekomster af "dett" på linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
566
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
567 ---> dett siges at dett er bedst at se på blomster når dett er forår.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
568
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
569 4. Ændr hver forekomst af en tegnstreng mellem to linjer,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
570 ved at skrive :#,#s/gammel/ny/g hvor #,# er linjenumrene over området
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
571 af linjer hvor udskiftningen skal ske.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
572 Skriv :%s/gammel/ny/g for at ændre hver forekomst i hele filen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
573 Skriv :%s/gammel/ny/gc for at finde hver forekomst i hele filen,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
574 med en prompt om hvorvidt der skal udskiftes eller ej.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
575
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
576 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
577 Lektion 4 OPSUMMERING
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
578
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
579
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
580 1. CTRL-G viser din placering i filen og filstatussen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
581 G flytter til slutningen af filen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
582 nummer G flytter til linjenummeret.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
583 gg flytter til den første linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
584
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
585 2. Når der skrives / efterfulgt af en frase, så søges der FREMAD efter frasen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
586 Når der skrives ? efterfulgt af en frase, så søges der BAGLÆNS efter frasen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
587 Skriv n efter en søgning, for at finde den næste forekomst i den samme retning,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
588 eller N for at søge i den modsatte retning.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
589 CTRL-O tager dig tilbage til ældre placeringer, CTRL-I til nyere placeringer.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
590
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
591 3. Når der skrives % mens markøren er på et (,),[,],{, eller }, så går den til dens match.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
592
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
593 4. Udskift den første første gammel med ny på en linje, ved at skrive :s/gammel/ny
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
594 Udskift alle gammel med ny på en linje, ved at skrive :s/gammel/ny/g
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
595 Udskift fraser mellem to linenumre, ved at skrive :#,#s/gammel/ny/g
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
596 Udskift alle forekomster i filen, ved at skrive :%s/gammel/ny/g
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
597 Spørg om bekræftelse hver gang, ved at tilføje 'c' :%s/gammel/ny/gc
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
598
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
599 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
600 Lektion 5.1: UDFØR EN EKSTERN KOMMANDO
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
601
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
602
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
603 ** Skriv :! efterfulgt af en ekstern kommando, for at udføre kommandoen. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
604
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
605 1. Skriv den velkendte kommando : for at sætte markøren nederst på
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
606 skærmen. Det giver dig mulighed for at indtaste en kommandolinjekommando.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
607
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
608 2. Skriv nu !-tegnet (udråbstegn). Det giver dig mulighed
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
609 for at udføre enhver ekstern skalkommando.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
610
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
611 3. Skriv f.eks. ls efter ! og tryk så på <ENTER>. Det
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
612 viser dig en liste over din mappe, ligesom hvis du var ved
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
613 skalprompten. Eller brug :!dir hvis ikke ls virker.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
614
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
615 BEMÆRK: Det er muligt at udføre enhver ekstern kommando på denne måde,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
616 også med argumenter.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
617
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
618 BEMÆRK: Alle :-kommandoer skal afsluttes ved at trykke på <ENTER>.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
619 Vi nævner det ikke altid herefter.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
620
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
621
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
622 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
623 Lektion 5.2: MERE OM AT SKRIVE FILER
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
624
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
625
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
626 ** Gem ændringerne som er foretaget til teksten, ved at skrive :w FILNAVN. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
627
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
628 1. Skriv :!dir eller :!ls for at få en liste over din mappe.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
629 Du ved allerede at du skal trykke på <ENTER> bagefter.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
630
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
631 2. Vælg et filnavn som ikke findes endnu, såsom TEST.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
632
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
633 3. Skriv nu: :w TEST (hvor TEST er filnavnet som du vælger.)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
634
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
635 4. Det gemmer hele filen (Vim-vejledningen) under navnet TEST.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
636 Bekræft det, ved igen at skrive :!dir eller :!ls for at se din mappe.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
637
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
638 BEMÆRK: Hvis du afslutter Vim og starter den igen med vim TEST , så vil
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
639 filen være en nøjagtig kopi af vejledningen da du gemte den.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
640
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
641 5. Fjern nu filen, ved at skrive (MS-DOS): :!del TEST
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
642 eller (Unix): :!rm TEST
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
643
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
644
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
645 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
646 Lektion 5.3: MARKÉR TEKST SOM SKAL SKRIVES
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
647
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
648
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
649 ** Gem en del af en fil, ved at skrive v bevægelse :w FILNAVN **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
650
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
651 1. Flyt markøren til denne linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
652
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
653 2. Tryk på v og flyt markøren til the femte punkt nedenfor. Bemærk at
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
654 teksten er fremhævet.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
655
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
656 3. Tryk på :-tegnet . Nederst på skærmen vises :'<,'>.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
657
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
658 4. Skriv w TEST , hvor TEST er filnavnet som endnu ikke findes. Bekræft
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
659 at du ser :'<,'>w TEST inden du trykker på <ENTER>.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
660
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
661 5. Vim skriver de markerede linjer til filen TEST. Brug :!dir eller :!ls
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
662 for at se den. Fjern den ikke endnu! Vi bruger den i den næste lektion.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
663
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
664 BEMÆRK: Når der trykkes på v startes visuel markering. Du kan flytte markøren
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
665 rundt for at gøre markeringen større eller mindre. Du kan så bruge en
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
666 operator til at gøre noget med teksten. F.eks. vil d slette teksten.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
667
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
668 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
669 Lektion 5.4: INDHENT OG SAMMENLÆG FILER
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
670
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
671
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
672 ** Indsæt indholdet af en fil, ved at skrive :r FILNAVN **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
673
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
674 1. Placer markøren lige ovenover denne linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
675
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
676 BEMÆRK: Når trin 2 er udført vil du se teksten fra lektion 5.3. Flyt så
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
677 NED for at se denne lektion igen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
678
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
679 2. Indhent nu din TEST-fil med kommandoen :r TEST , hvor TEST er
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
680 navnet på filen som du brugte.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
681 Filen som du indhenter placeres under markørens linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
682
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
683 3. Bekræft at en fil blev indhentet, ved at flytte markøren tilbage og bemærk
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
684 at der nu er to kopier af lektion 5.3, den originale og filversionen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
685
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
686 BEMÆRK: Du kan også læse outputtet fra en ekstern kommando. F.eks. læser
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
687 :r !ls outputtet fra ls-kommandoen og indsætter det under
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
688 markøren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
689
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
690
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
691 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
692 Lektion 5 OPSUMMERING
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
693
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
694
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
695 1. :!kommando udfører en ekstern kommando.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
696
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
697 Nogle nyttige eksempler er:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
698 (MS-DOS) (Unix)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
699 :!dir :!ls - viser en liste over mapper.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
700 :!del FILNAVN :!rm FILNAVN - fjerner filen FILNAVN.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
701
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
702 2. :w FILNAVN skriver den nuværende Vim-fil til disken med navnet FILNAVN.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
703
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
704 3. v bevægelse :w FILNAVN gemmer de visuelt markerede linjer i filen
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
705 FILNAVN.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
706
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
707 4. :r FILNAVN indhenter diskfilen FILNAVN og indsætter den under
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
708 markørens placering.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
709
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
710 5. :r !dir læser outputtet fra dir-kommandoen og indsætter det under
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
711 markørens placering.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
712
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
713
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
714 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
715 Lektion 6.1: ÅBN-KOMMANDOEN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
716
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
717
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
718 ** Skriv o for at åbne en linje under markøren og stille dig i indsæt-tilstand. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
719
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
720 1. Flyt markøren ned til linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
721
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
722 2. Skriv bogstavet o med småt, for at åbne en linje UNDER markøren og stille
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
723 dig i indsæt-tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
724
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
725 3. Skriv nu noget tekst og tryk på <ESC> for at afslutte indsæt-tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
726
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
727 ---> Efter o er blevet skrevet, placeres markøren på den åbne linje i indsæt-tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
728
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
729 4. Skriv blot et stort O , i stedet for et lille o , for at
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
730 åbne en linje OVENOVER markøren. Prøv det på linjen nedenfor.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
731
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
732 ---> Åbn en line ovenover denne, ved at skrive O mens markøren er på denne linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
733
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
734
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
735
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
736
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
737 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
738 Lektion 6.2: VEDHÆFT-KOMMANDOEN
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
739
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
740
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
741 ** Skriv a for at indsætte tekst EFTER markøren. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
742
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
743 1. Flyt markøren ned til begyndelsen af linjen med --->.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
744
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
745 2. Tryk på e indtil markøren er på slutningen af lin .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
746
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
747 3. Skriv et a (med småt) for at vedhæfte tekst EFTER markøren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
748
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
749 4. Fuldfør ordet ligesom linjen under det. Tryk på <ESC> for at afslutte
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
750 indsæt-tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
751
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
752 5. Brug e til at flytte til det næste ufærdige ord og gentag trin 3 og 4.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
753
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
754 ---> Lin giver dig mulighed for at øv vedhæftnin af tekst til en linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
755 ---> Linjen giver dig mulighed for at øve vedhæftning af tekst til en linje.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
756
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
757 BEMÆRK: a, i og A går alle til den samme indsæt-tilstand,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
758 den eneste forskel er hvor tegnene indsættes.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
759
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
760 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
761 Lektion 6.3: AN ANDEN MÅDE AT ERSTATTE
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
762
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
763
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
764 ** Skriv et stort R for at erstatte flere end ét tegn. **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
765
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
766 1. Flyt markøren ned til den første linje med --->. Flyt markøren til
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
767 begyndelsen af den første xxx .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
768
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
769 2. Tryk nu på R og skriv nummeret som er under det på den anden linje,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
770 så det erstatter xxx .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
771
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
772 3. Tryk på <ESC> for at forlade erstat-tilstand. Bemærk at resten af linjen
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
773 forbliver uændret.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
774
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
775 4. Gentag trinnene for at erstatte det sidste xxx.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
776
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
777 ---> Når 123 lægges sammen med xxx giver det xxx.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
778 ---> Når 123 lægges sammen med 456 giver det 579.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
779
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
780 BEMÆRK: Erstat-tilstand er ligesom indsæt-tilstand, men hvert indtastede
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
781 tegn sletter et eksisterende tegn.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
782
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
783 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
784 Lektion 6.4: KOPÍER OG INDSÆT TEKST
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
785
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
786
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
787 ** Brug y-operatoren til at kopiere tekst og p til at indsætte den **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
788
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
789 1. Gå ned til linjen med ---> og placer markøren efter "a)".
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
790
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
791 2. Start visuel tilstand med v og flyt markøren til lige inden "første".
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
792
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
793 3. Skriv y for at yank-udtrække (kopiere) den fremhævede tekst.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
794
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
795 4. Flyt markøren til slutningen af den næste linje: j$
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
796
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
797 5. Skriv p for at put-indsætte (indsætte) teksten. Skriv så: a andet <ESC> .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
798
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
799 6. Brug visuel tilstand til at markere " punkt.", yank-udtræk med y , flyt
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
800 til slutningen af næste linje med j$ og put-indsæt teksten der med p .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
801
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
802 ---> a) dette er det første punkt.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
803 b)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
804
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
805 BEMÆRK: du kan også bruge y som en operator; yw yank-udtrækker et ord.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
806 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
807 Lektion 6.5: SÆT VALGMULIGHED
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
808
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
809
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
810 ** Sæt en valgmulighed så en søgning eller udskiftning ignorerer forskelle på store/små bogstaver **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
811
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
812 1. Søg efter 'ignorer', ved at skrive: /ignorer <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
813 Gentag flere gange ved at trykke på n .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
814
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
815 2. Sæt 'ic'-valgmuligheden (Ignorer forskelle på store/små bogstaver), ved at skrive: :set ic
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
816
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
817 3. Søg nu efter 'ignorer' igen, ved at trykke på n
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
818 Bemærk at Ignorer og IGNORER nu også bliver fundet.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
819
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
820 4. Sæt 'hlsearch'- og 'incsearch'-valgmulighederne: :set hls is
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
821
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
822 5. Skriv nu søg-kommandoen igen og se hvad der sker: /ignorer <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
823
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
824 6. Deaktivér ignorering af forskelle på store/små bogstaver, ved at skrive: :set noic
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
825
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
826 BEMÆRK: Fjern fremhævningen af matches, ved at skrive: :nohlsearch
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
827 BEMÆRK: Hvis du vil ignorere case for en enkelt søg-kommando, så brug \c
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
828 i frasen: /ignorer\c <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
829 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
830 Lektion 6 OPSUMMERING
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
831
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
832 1. Skriv o for at åbne en linje NEDENUNDER markøren og starte indsæt-tilstand.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
833 Skriv O for at åbne en linje OVENOVER markøren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
834
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
835 2. Skriv a for at indsætte tekst EFTER markøren.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
836 Skriv A for at indsætte tekst efter slutningen af linjen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
837
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
838 3. e-kommandoen flytter til slutningen af et ord.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
839
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
840 4. y-operatoren yank-udtrækker (kopierer) tekst, p put-indsætter (indsætter) den.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
841
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
842 5. Når der skrives et stort R stilles du i erstat-tilstand indtil der trykkes på <ESC> .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
843
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
844 6. Når der skrives ":set xxx", så sættes valgmuligheden "xxx". Nogle valgmuligheder er:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
845 'ic' 'ignorecase' ignorer forskelle på store/små bogstaver når der søges
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
846 'is' 'incsearch' vis delvise match for en søgefrase
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
847 'hls' 'hlsearch' fremhæv alle fraser som matcher
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
848 Du kan enten bruge det lange eller korte valgmulighedsnavn.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
849
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
850 7. Vedhæft "no" i begyndelsen, for at slå en valgmulighed fra: :set noic
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
851
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
852 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
853 Lektion 7.1: FÅ HJÆLP
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
854
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
855
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
856 ** Brug online-hjælpesystemet **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
857
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
858 Vim har et omfattende online-hjælpesystem. Prøv en af disse tre,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
859 for at komme i gang:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
860 - tryk på <HELP>-tasten (hvis du har en)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
861 - tryk på <F1>-tasten (hvis du har en)
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
862 - skriv :help <ENTER>
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
863
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
864 Læs teksten i hjælpevinduet for at finde ud af hvordan hjælpen virker.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
865 Skriv CTRL-W CTRL-W for at hoppe fra et vindue til et andet.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
866 Skriv :q <ENTER> for at lukke hjælpevinduet.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
867
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
868 Du kan finde hjælp om næsten alle emner, ved at give et argument til
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
869 ":help"-kommandoen. Prøv disse (husk at trykke på <ENTER>):
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
870
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
871 :help w
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
872 :help c_CTRL-D
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
873 :help insert-index
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
874 :help user-manual
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
875 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
876 Lektion 7.2: OPRET ET OPSTARTS-SCRIPT
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
877
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
878
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
879 ** Aktivér Vim-funktionaliteter **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
880
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
881 Vim har mange flere funktionaliteter end Vi, men de fleste er deaktiveret som
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
882 standard. For at bruge flere funktionaliteter skal du oprette en "vimrc"-fil.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
883
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
884 1. Begynd at redigere "vimrc"-filen. Det afhænger af dit system:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
885 :e ~/.vimrc i Unix
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
886 :e $VIM/_vimrc i MS-Windows
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
887
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
888 2. Læs nu indholdet af eksempel "vimrc"-filen:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
889 :r $VIMRUNTIME/vimrc_example.vim
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
890
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
891 3. Skriv filen med:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
892 :w
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
893
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
894 Næste gang du starter Vim bruger den syntaksfremhævning.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
895 Du kan tilføje alle dine foretrukne indstillinger til "vimrc"-filen.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
896 Få mere information, ved at skrive :help vimrc-intro
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
897
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
898 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
899 Lektion 7.3: FULDFØRELSE
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
900
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
901
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
902 ** Kommandolinjefuldførelse med CTRL-D og <TAB> **
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
903
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
904 1. Sørg for at Vim ikke er i kompatibel tilstand: :set nocp
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
905
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
906 2. Se hvilke filer der er i mappen: :!ls eller :!dir
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
907
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
908 3. Skriv begyndelsen af en kommando: :e
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
909
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
910 4. Tryk på CTRL-D og Vim viser en liste over kommandoer der begynder med "e".
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
911
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
912 5. Tryk på <TAB> og Vim vil fuldføre kommandonavnet til ":edit".
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
913
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
914 6. Tilføj nu et mellemrum og begyndelsen af et eksisterende filnavn: :edit FIL
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
915
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
916 7. Tryk på <TAB>. Vim fuldfører navnet (hvis det er unikt).
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
917
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
918 BEMÆRK: Fuldførelse virker til mange kommandoer. Prøv blot at trykke på
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
919 CTRL-D og <TAB>. Det er særligt nyttigt til :help .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
920
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
921 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
922 Lektion 7 OPSUMMERING
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
923
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
924
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
925 1. Skriv :help eller tryk på <F1> eller <Help> for at åbne et hjælpevindue.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
926
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
927 2. Skriv :help kommando for at finde hjælp om kommando .
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
928
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
929 3. Skriv CTRL-W CTRL-W for at hoppe til et andet vindue
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
930
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
931 4. Skriv :q for at lukke hjælpevinduet
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
932
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
933 5. Opret et vimrc-opstarts-script for at bevare dine foretrukne indstillinger.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
934
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
935 6. Når der skrives en :-kommando , så tryk på CTRL-D for at se
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
936 mulige fuldførelser. Tryk på <TAB> for at bruge en fuldførelse.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
937
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
938
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
939
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
940
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
941
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
942
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
943
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
944 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
945
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
946 Det afslutter Vim-vejledningen. Det var meningen den skulle give et
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
947 kortfattet overblik af Vim-editoren, lige nok til at du kan bruge editoren
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
948 nogenlunde let. Den er langt fra komplet, da Vim har mange mange flere
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
949 kommandoer. Læs brugermanualen som det næste: ":help user-manual".
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
950
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
951 Denne bog anbefales, til yderligere læsning og studering:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
952 Vim - Vi Improved - af Steve Oualline
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
953 Forlag: New Riders
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
954 Den første bog som helt er tilegnet Vim. Specielt nyttig for begyndere.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
955 Der er mange eksempler og billeder.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
956 Se http://iccf-holland.org/click5.html
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
957
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
958 Denne bog er ældre og mere om Vi end Vim, men anbefales også:
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
959 Learning the Vi Editor - af Linda Lamb
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
960 Forlag: O'Reilly & Associates Inc.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
961 Det er en god bog til at komme til kende næsten alt hvad du vil gøre med Vi.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
962 Den sjette udgave inkluderer også information om Vim.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
963
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
964 Vejledningen blev skrevet af Michael C. Pierce og Robert K. Ware,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
965 Colorado School of Mines med ideer af Charles Smith,
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
966 Colorado State University. E-mail: bware@mines.colorado.edu.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
967
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
968 Ændret til Vim af Bram Moolenaar.
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
969
15878
314694a2e74a Update runtime files.
Bram Moolenaar <Bram@vim.org>
parents: 14298
diff changeset
970 Oversat af scootergrisen.
14298
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
971
4a588e3afd4a Update runtime files, add Danish translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
972 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~