【备忘录】环境配置与小工具类

vim自动添加头文件

以下是C语言的文件头配置,其他语言类似。

"******************配置文件头****************

func SetTitle()
if &filetype == 'c'
	call setline(1, "/* ")
	call setline(2, "* Author:		[email protected]") 
	call setline(3, "* ")
	call setline(4, "* Created Time: ".strftime("%c"))
	call setline(5, "* ")
	call setline(6, "* FileName:     ".expand("%"))
	call setline(7, "* ")
	call setline(8, "* Description:  ")
	call setline(9, "*")
	call setline(10,"*/")
	call setline(11,"")
	call setline(12, "#include <stdio.h>")
	call setline(13, "#include <stdlib.h>")
endif
endfunc

 

autocmd BufNewFile *.c ":call SetTitle()"


参考文章:

vim自动添加文件头



yakuake:一个好用的下拉式shell终端

ununtu下直接sudo apt-get install yakuake下载,简单粗暴。


NC(NetCat)命令

使用方法:nc ip地址 端口号
开始监听。 例如:nc 127.0.0.1 8086
适用于监听服务端的各种消息。依然简单粗暴。

参考资料
NC(NetCat)用法/命令详解

你可能感兴趣的:(【备忘录】环境配置与小工具类)