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
@TheCedarPrince
TheCedarPrince / init.vim
Last active November 17, 2022 09:28
My (neo)Vim Configuration File
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" VIM SETTINGS
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" TURNS LINE NUMBERING ON
set nu
" TRIGGER `autoread` WHEN FILES CHANGES ON DISK
set autoread
autocmd FocusGained,BufEnter,CursorHold,CursorHoldI * if mode() != 'c' | checktime | endif
@nezuo
nezuo / testez-selene.md
Last active March 3, 2024 14:17
TestEZ standard library for selene

Instructions

  1. Copy the file below into one called testez.yml
  2. In selene.toml, replace std = "roblox" with std = "roblox+testez"
@rougier
rougier / nano.el
Created October 2, 2020 17:44
A very minimal emacs configuration
;; nano.el -- A very minimal emacs
;; Usage: emacs -q -l nano.el
;;
;; Copyright (C) 2020 Nicolas .P Rougier
;;
;; Author: Nicolas P. Rougier <nicolas.rougier@inria.fr>
;;
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
@progfolio
progfolio / general-spacemacs.org
Last active March 20, 2024 17:04
Spacemacs-like menus using general.el

Spacemacs-like menus using general.el

Global keybindings

First, we define a global prefix key:

(general-create-definer global-definer
  :keymaps 'override
  :states  '(insert emacs normal hybrid motion visual operator)
  :prefix  "SPC"
  :non-normal-prefix "S-SPC")
@mg979
mg979 / import.vim
Last active March 8, 2024 18:30
Import Ultisnips snippets in vim-vsnip
" ========================================================================///
" Description: import UltiSnips snippets as VsCode snippets for vim-vsnip
" File: import.vim
" Author: Gianmaria Bajo <mg1979@git.gmail.com>
" License: MIT
" Created: dom 09 agosto 2020 13:14:35
" Modified: dom 09 agosto 2020 15:33:32
" ========================================================================///
function! import#snippets(ask_confirm) abort
@windwp
windwp / i3-swallow.py
Last active January 4, 2023 11:27
i3-swallow used to swallow a terminal window in i3
#!/usr/bin/env python3
#-----------------------------------------------
# used to swallow a terminal window in i3
#
# INSTALL
# Install python 3 and install i3ipc libary
# pip3 install i3ipc
# download this scrript and put it to your i3 config folder and run
@phelipetls
phelipetls / lsp.lua
Last active December 9, 2022 18:21
Neovim built-in LSP diagnostics into location list
local severity_map = { "E", "W", "I", "H" }
local parse_diagnostics = function(diagnostics)
if not diagnostics then return end
local items = {}
for _, diagnostic in ipairs(diagnostics) do
local fname = vim.fn.bufname()
local position = diagnostic.range.start
local severity = diagnostic.severity
table.insert(items, {
@romainl
romainl / path.md
Last active April 17, 2024 07:42
Off the beaten path

Off the beaten path

What is &path used for?

Vim uses :help 'path' to define the root directories from where to search non-recursively for files.

It is used for:

  • gf, gF, <C-w>f, <C-w>F, <C-w>gf, <C-w>gF,
  • :find, :sfind, :tabfind,
@Daivasmara
Daivasmara / NVIM
Last active February 17, 2024 10:34
NVIM v0.9.0
call plug#begin('~/.vim/plugged')
Plug 'challenger-deep-theme/vim', { 'as': 'challenger-deep' }
Plug 'morhetz/gruvbox'
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' }
Plug 'junegunn/fzf.vim'
Plug 'stsewd/fzf-checkout.vim'
Plug 'sheerun/vim-polyglot'
Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes'
@yegappan
yegappan / VimScriptForPythonDevelopers.MD
Last active January 12, 2024 10:51
Vim script for Python Developers

Vim Script for Python Developers

This is a guide to Vim Script development for Python developers. Sample code for the various expressions, statements, functions and programming constructs is shown in both Python and Vim Script. This is not intended to be a tutorial for developing Vim scripts. It is assumed that the reader is familiar with Python programming.

For an introduction to Vim Script development, refer to usr_41.txt, eval.txt and Learn Vimscript the Hard Way

For a guide similar to this one for JavaScript developers, refer to Vim Script for the JavaScripter

This guide only describes the programming constructs that are present in both Python and Vim. The constructs that are unique to Vim (e.g. autocommands, [key-mapping](https://vimhelp.org/map.txt.html#key-m