Ⅰ. 插件描述
Vim plugin for emulating Windows Notepad's logging functionalityⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin '/logpad-vim'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle '/logpad-vim'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug '/logpad-vim'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/vim-scripts/logpad.vim
Ⅳ. 文档说明
logpad.vim emulates Windows Notepad's logging feature.
Create a new file, write .LOG as the first line and save it. Every time you reopen the file, a new line with the current timestamp is added, so you can easily maintain a chronologic log of your tasks.
By default, this plugin works the same way as the original Notepad. You can modify certain aspects of it by setting the following variables:
let LogpadEnabled = [ 0 / 1 ]
- enables/disables logpad
- default value: 1
let LogpadInsert = [ 0 / 1 ]
- automatically enables &insertmode when a new log entry is created
- default value: 0
let LogpadLineBreak = [ 0 / 1 ]
- adds an empty line before a new log entry
- default value: 0 (Windows Notepad behavior)
let LogpadIgnoreNotes = [ 0 / 1 ]
- allows adding notes before the first log entry
- default value: 0
let LogpadIgnoreReadOnly = [ 0 / 1 ]
- allows logpad to ignore a file's read-only flag
- default value: 0