Created
January 16, 2012 06:46
-
-
Save yoshio-kinoshita/1619456 to your computer and use it in GitHub Desktop.
vimでシーケンス
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| vimでシーケンスを作成する。 | |
| 数値にカーソルを合わせてCtrl + a でカウントアップできますが、 | |
| デフォルト設定だと数値が8進数、16進数としてカウントアップします。 | |
| 業務だと10進数を扱うことのほうが多いと思うので | |
| :set nrformats= | |
| で数値インクリメントオプションをクリアします。 | |
| これで10進数としてカウントアップできます。 | |
| 次にマクロでシーケンスを作成します。 | |
| スタート値にカーソルを合わせる | |
| マクロ記録開始 | |
| Shift + vで行選択 | |
| ヤンク | |
| ペースト | |
| Ctrl + aでカウントアップ | |
| マクロ終了 | |
| これで簡単にシーケンスが作れます。 | |
| 0 | |
| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| こんな感じ。 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment