Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
[PL] Jak napisać prosty plugin do VIMa w Pythonie
Search
Łukasz Balcerzak
November 12, 2012
Programming
0
260
[PL] Jak napisać prosty plugin do VIMa w Pythonie
Łukasz Balcerzak
November 12, 2012
Tweet
Share
More Decks by Łukasz Balcerzak
See All by Łukasz Balcerzak
Python 3 w 2013 i trochę o przyszłości
lukaszb
0
230
[PL] Porunga - narzędzie do testowania algorytmów
lukaszb
0
58
[PL] Automatyzacja Testów
lukaszb
2
140
Other Decks in Programming
See All in Programming
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
580
CSC307 Lecture 01
javiergs
PRO
0
690
並行開発のためのコードレビュー
miyukiw
0
220
360° Signals in Angular: Signal Forms with SignalStore & Resources @ngLondon 01/2026
manfredsteyer
PRO
0
130
そのAIレビュー、レビューしてますか? / Are you reviewing those AI reviews?
rkaga
6
4.6k
SourceGeneratorのススメ
htkym
0
200
React 19でつくる「気持ちいいUI」- 楽観的UIのすすめ
himorishige
11
7.4k
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.9k
AWS re:Invent 2025参加 直前 Seattle-Tacoma Airport(SEA)におけるハードウェア紛失インシデントLT
tetutetu214
2
110
Data-Centric Kaggle
isax1015
2
780
Unicodeどうしてる? PHPから見たUnicode対応と他言語での対応についてのお伺い
youkidearitai
PRO
1
2.6k
dchart: charts from deck markup
ajstarks
3
990
Featured
See All Featured
Between Models and Reality
mayunak
1
190
AI Search: Implications for SEO and How to Move Forward - #ShenzhenSEOConference
aleyda
1
1.1k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
830
Are puppies a ranking factor?
jonoalderson
1
2.7k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
svc-hook: hooking system calls on ARM64 by binary rewriting
retrage
1
100
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
26
3.3k
How STYLIGHT went responsive
nonsquared
100
6k
Building Adaptive Systems
keathley
44
2.9k
The Straight Up "How To Draw Better" Workshop
denniskardys
239
140k
Design in an AI World
tapps
0
140
Building Applications with DynamoDB
mza
96
6.9k
Transcript
Jak napisać prosty plugin do VIMa w Pythonie Łukasz Balcerzak
Tuesday, November 13, 12
O mnie • Łukasz Balcerzak •
[email protected]
• github.com/lukaszb •
bitbucket.org/lukaszb • @lbalcerzak Tuesday, November 13, 12
Plan • Struktura plugin’ów VIM’a • Podstawowy skrypt .vim (klej)
• Testowanie • Problemy Tuesday, November 13, 12
Struktura • myplugin/ • myplugin/plugin/ • myplugin/plugin/myplugin/ <= pliki *.py
• myplugin/plugin/myplugin.vim <= klej • myplugin/doc/myplugin.txt Tuesday, November 13, 12
Struktura 2 • Taka struktura ułatwia innym użytkownikom używanie plugin’u
• zazwyczaj wystarczy wrzucić do ~/.vim/ bundle/ Tuesday, November 13, 12
Klej • Nawet najprostszy plugin musimy zacząć od pisania w
... vim scripting language Tuesday, November 13, 12
Klej 2 Tuesday, November 13, 12
Klej 3 Tuesday, November 13, 12
Python - nareszcie Tuesday, November 13, 12
Python - i tyle? • Oczywiście, że nie ... Tuesday,
November 13, 12
Python - i tyle? Tuesday, November 13, 12
+ testy • Testowanie to tak naprawdę najciekawsza część tworzenie
plugin’a Tuesday, November 13, 12
+ testy • Standardowo: - uruchamiamy vim’a - wpisujemy tekst/otwieramy
bufor z przygotowanym tekstem - ustawiamy kursor w odpowiednim miejscu - odpalamy :MyPluginFunction() Tuesday, November 13, 12
+ testy Tuesday, November 13, 12
+ testy • Ups... no ale to Python! Przecież testowanie
jest łatwe i przyjemne! Tuesday, November 13, 12
+ testy Tuesday, November 13, 12
+ testy Tuesday, November 13, 12
+ testy • Problem? Tuesday, November 13, 12
+ testy • Work in progress: • https://github.com/lukaszb/vimmock Tuesday, November
13, 12
+ testy Tuesday, November 13, 12
Demo Tuesday, November 13, 12
Problem? • Python3 • Większość pluginów jest już napisana ...
• http://www.vim.org/scripts/index.php • http://vim-scripts.org/ Tuesday, November 13, 12
Linki / inne • github.com/lukaszb/vimmock • github.com/lukaszb/vimper • @lbalcerzak •
[email protected]
Tuesday, November 13, 12
Pytania? • github.com/lukaszb/vimmock • github.com/lukaszb/vimper • github.com/lukaszb/superpy Tuesday, November 13,
12