Skip to content

Instantly share code, notes, and snippets.

View Sebastian1011's full-sized avatar
🗯️

Sebastian Zhang Sebastian1011

🗯️
View GitHub Profile
@Sebastian1011
Sebastian1011 / gdb.md
Last active December 4, 2023 15:53
Mac use gdb

Install Neovim on Mac

install nvim

$ brew install neovim

add vimrc

$ cp vimrc ~/.vimrc

@Sebastian1011
Sebastian1011 / Vim-C_C++.md
Last active December 1, 2023 07:00
Vim/Nvim C/C++ Editor

Vim C/C++

Install ctags

$ git clone https://github.com/universal-ctags/ctags.git

$ cd ctags
$ sudo locale-gen zh_CN.UTF-8
$ vi ~/.bashrc
```
export LANG=en_US.UTF-8
export LANGUAGE=
export LC_CTYPE="en_US.UTF-8"
export LC_NUMERIC=zh_CN.UTF-8
export LC_TIME=zh_CN.UTF-8

$ sudo adduser git

$ su git

$ cd

$ mkdir .ssh && chmod 700 .ssh

$ touch .ssh/authorized_keys && chmod 600 .ssh/authorized_keys

@Sebastian1011
Sebastian1011 / SpringBoot_RestTemplate_vs_HttpClient.md
Last active April 21, 2018 10:36
Spring boot RestTemplate vs HttpClient
firstly, RestTemplate and HttpCient don't operate the same abstraction level.

HttpClient is a general-purpose lib to communicate using HTTP, but RestTemplate is a highter-level abstraction, dealing with Jons/xml transformation of entities. RestTemplate delegates to a ClientHttpFactory , and one of the implementations of this interface uses HttpClient.

mount -t nfs $ip:/mnt/SHEC0001 /share -o nolock
@Sebastian1011
Sebastian1011 / Edit_Linux_desktop_icorn.md
Last active December 1, 2023 05:43
remove icons from linux launcher

remove icons from linux launcher

path: .local/share/application

@Sebastian1011
Sebastian1011 / bashCollection
Created March 21, 2017 06:00
bash find and delete files
find . -name "*.orig" -delete
@Sebastian1011
Sebastian1011 / new_gist_file_0
Created March 2, 2017 11:07
window开放端口
或者在管理员权限的cmd里打这句命令:
netsh advfirewall firewall add rule name="SecurityGateMaster_PortOpen" protocol=TCP dir=in localport=8080,9999,3306,9910,21200,21500 action=allow