Skip to content

Instantly share code, notes, and snippets.

View ur4ltz's full-sized avatar

Andy Shevchenko ur4ltz

  • Kharkiv - Ukraine, Glory to Ukraine
View GitHub Profile
{
"suggest.noselect": false,
"coc.preferences.formatOnSaveFiletypes": [
"javascript",
"typescript",
"typescriptreact",
"json",
"javascriptreact",
"typescript.tsx",
"graphql"
@ur4ltz
ur4ltz / init.vim
Created January 10, 2020 01:33 — forked from benawad/init.vim
" Specify a directory for plugins
call plug#begin('~/.vim/plugged')
Plug 'neoclide/coc.nvim', {'branch': 'release'}
Plug 'scrooloose/nerdtree'
"Plug 'tsony-tsonev/nerdtree-git-plugin'
Plug 'Xuyuanp/nerdtree-git-plugin'
Plug 'tiagofumo/vim-nerdtree-syntax-highlight'
Plug 'ryanoasis/vim-devicons'
Plug 'airblade/vim-gitgutter'
@ur4ltz
ur4ltz / crontab
Created December 1, 2019 15:08 — forked from mdeangelo001/crontab
Reboot dd-wrt router via web interface and curl
# My DD-WRT router would not reboot reliably except by going through the web interface.
# The reboot settings in the UI did not work consistently, and ssh access did not work
# reliably either. I was able to figure out the following curl command that makes the
# basically presses the Reboot Router button on the Administration->Management screen.
# This crontab reboots the router every night at 3:30 am
30 3 * * * /usr/bin/curl --referer http://192.168.1.1/Management.asp -d submit_button=Management -d action=Reboot -u admin:password --http1.1 -v http://192.168.1.1/apply.cgi
@ur4ltz
ur4ltz / install-vim-8-with-python-ruby-lua-opensuse.sh
Created November 11, 2019 16:15 — forked from Skrip42/install-vim-8-with-python-ruby-lua-opensuse.sh
Install Vim 8 with Python, Python 3, Ruby (2.5) and Lua support on openSuse
# remove current vim
sudo zypper rm vim vim-runtime vim-gnome vim-tiny vim-gui-common
# removes current link for vim
sudo rm -rf /usr/local/share/vim /usr/bin/vim
# installs everything needed to make/configure/build Vim
sudo zypper in \
lua51-luajit \
lua51-luajit-devel \
@ur4ltz
ur4ltz / 24-bit-color.patch
Created July 17, 2019 17:38 — forked from cpixl/24-bit-color.patch
24-bit color patch for URxvt version 9.22 (based on https://github.com/spudowiar/rxvt-unicode)
--- README.configure
+++ README.configure
@@ -9,8 +9,8 @@ CONFIGURE OPTIONS
--enable-everything
Add (or remove) support for all non-multichoice options listed in
- "./configure --help", except for "--enable-assert" and
- "--enable-256-color".
+ "./configure --help", except for "--enable-assert",
+ "--enable-256-color" and "--enable-24-bit-color".
@ur4ltz
ur4ltz / httpd-cgit.conf
Created April 14, 2019 16:00 — forked from ap/httpd-cgit.conf
cgit clean URLs Apache config
# cgit setup for Apache that results in completely clean URLs, ie.
# visiting http://git.example.org/ will produce the cgit index page
<VirtualHost *>
# this part is stand fare
ServerName git.example.org
DocumentRoot /var/www/htdocs/cgit/
<Directory "/var/www/htdocs/cgit/">
AllowOverride None
Options ExecCGI
Order allow,deny
@ur4ltz
ur4ltz / vim_article-1.md
Created February 2, 2019 19:00 — forked from sagax/vim_article-1.md
vim article-1

Такого еще не было на данном ресурсе, и надеюсь, что сообщество поддержит инициативу. Есть предложение, сделать живую статью, в которой все мы будем выкладывать клавиатурные сочетания, которые каждый из нас использует в повседневной работе с Vim. Я обязуюсь анализировать комментарии и добавлять в статью новые клавиатурные сочетания. Если клавиатурное сочетание использует какой-то плагин, то указываем его имя.


Навигация:

  • ge - перейти к концу предыдущего слова

Замена текста:

@ur4ltz
ur4ltz / vimawesome.vim
Last active November 14, 2019 00:12 — forked from junegunn/vimawesome.vim
Plugin completion using VimAwesome API
" ----------------------------------------------------------------------------
" vimawesome.com
" ----------------------------------------------------------------------------
function! VimAwesomeComplete() abort
let prefix = matchstr(strpart(getline('.'), 0, col('.') - 1), '[.a-zA-Z0-9_/-]*$')
echohl WarningMsg
echo 'Downloading plugin list from VimAwesome'
echohl None
ruby << EOF
require 'json'
" put this into your .vimrc
func! Run_current_line()
" get current line and run it as a system command
let content = system(getline('.'))
" open new window
silent pedit `=tempname()`
" change focus to the window
wincmd P
" append content
@ur4ltz
ur4ltz / gist:878e00df4233d2f0faee
Created September 25, 2015 13:46 — forked from kien/gist:1610859
Custom statusline example
" File: after/plugin/ctrlp.vim
" Description: Custom statusline example
" Make sure ctrlp is installed and loaded
if !exists('g:loaded_ctrlp') || ( exists('g:loaded_ctrlp') && !g:loaded_ctrlp )
fini
en
" ctrlp only looks for this