How to disable automatic comment insertion in Vim
How to disable automatic comment insertion in Vim?
Add to ~/.vimrc
:
au FileType c,cpp setlocal comments-=:// comments+=f://
More: http://vim.wikia.com/wiki/Disable_automatic_comment_insertion
How to disable automatic comment insertion in Vim?
Add to ~/.vimrc
:
au FileType c,cpp setlocal comments-=:// comments+=f://
More: http://vim.wikia.com/wiki/Disable_automatic_comment_insertion
Git’s tags are convenient use to name some specific commits by tagging them for releasing or book keeping purposes. For example, GitHub allows repository managers to make releases using git tags. However, it may happen by mistake that a git tag is pushed to the remote git server while the tag has been made to…
Where are the files for data of the moden metro apps stored in Windows 10? The files for data of the metro apps in Windows is stored under %userprofile%AppDataLocalPackages You can enter the string in the Explore and hit enter to open the directory directly. Read more: Where are the Linux routing table entries stored…
In system, sometimes, we need backstage threads with very very low priority since it cannot preempt any normal process asks for CPU. SCHED_IDLE class satisfies this requirement which has the priority lower than “nice=19” of CFS. Following code does this. 241 void set_idle_priority(void) { 242 struct sched_param param; 243 param.sched_priority = 0; 244 int s…
In C, how to get the hostname of the node? In C, you may use the gethostname function. #include <unistd.h> int gethostname(char *name, size_t namelen); The gethostname() function shall return the standard host name for the current machine. The namelen argument shall specify the size of the array pointed to by the name argument. The…
How to import a source file to OCaml’s toplevel? Say, I want to use a function implemented in a source file in the toplevel. #use “file-name”;; Read, compile and execute source phrases from the given file. This is textual inclusion: phrases are processed just as if they were typed on standard input. The reading of…
Assumption: There are VBD based Xen DomU virtual machines stored under /home/xen/vm-f11-sample/. There are two files under vm-f11-sample: vm0-f11.run (The configuration file) and vmdisk0 (The virtual disk). Now we want to duplicate the virtual machine vm0 stored under vm-f11-sample to vm-10.0.0.213 which is stored under vm-10.0.0.213. And vm-10.0.0.213’s ip will be 10.0.0.213. The steps to…