Skip to content

Instantly share code, notes, and snippets.

@dseeni
dseeni / .gitignore_global
Created February 8, 2020 06:33 — forked from jacobtomlinson/.gitignore_global
An example global gitignore file
# An example global gitignore file
#
# Place a copy if this at ~/.gitignore_global
# Run `git config --global core.excludesfile ~/.gitignore_global`
# Compiled source #
###################
*.com
*.class
*.dll
@dseeni
dseeni / init.vim
Created February 9, 2020 02:12 — 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'
@dseeni
dseeni / init.vim
Created February 9, 2020 02:12 — 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'
# Basic console colors --------------------------------------------------------
[console]::backgroundcolor = "White"
[console]::foregroundcolor = "Black"
# Syntax highlighting colors --------------------------------------------------
set-PSReadlineOption -TokenKind command -ForegroundColor "DarkGray"
Set-PSReadlineOption -TokenKind comment -ForegroundColor "DarkGray"
Set-PSReadlineOption -TokenKind parameter -ForegroundColor "DarkGray"
@dseeni
dseeni / singleton.py
Created February 9, 2020 09:34 — forked from jnalley/singleton.py
A singleton "like" Python snippet using lru_cache
#!/usr/bin/env python3
from functools import lru_cache
class Singleton:
@lru_cache
def __new__(cls, *args, **kwargs):
return super().__new__(cls)
@dseeni
dseeni / git-bash-as-term
Created March 8, 2020 05:26 — forked from Zyst/git-bash-as-term
NeoVim use git bash as terminal
:term "C:\Program Files\Git\bin\bash.exe"
@dseeni
dseeni / NeovimCygwin.md
Created March 8, 2020 09:57 — forked from equalsraf/NeovimCygwin.md
Neovim in Cygwin

TLDR; no, libuv doesn't work in Cygwin just yet, see at the bottom.

Requirements

I tested using the master branch (9d3449852bd35c9283948186d0259c1bf73b8579 or later)

I installed the following in the cygwin setup

  • gcc-c++ make cmake pkg-config libtool
@dseeni
dseeni / Source_Code_Pro_Powershell_font.ps1
Created March 10, 2020 10:26 — forked from wormeyman/Source_Code_Pro_Powershell_font.ps1
Set Adobe's Source Code Pro as a PowerShell font option.
#Reference: http://michaellwest.blogspot.com/2013/03/add-font-to-powershell-console.html
#Reference: http://support.microsoft.com/default.aspx?scid=KB;EN-US;Q247815 This explains why we name it 000
Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Console\TrueTypeFont' #Get the properties of TTF
Set-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Console\TrueTypeFont' -Name 000 -Value 'Source Code Pro' #Set it to SCP
Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Console\TrueTypeFont' #Check to see if we properly set it so that SCP is an option
@dseeni
dseeni / vimura.md
Created March 12, 2020 04:29 — forked from vext01/vimura.md
Vim+Zathura+Synctex

Vim+Zathura+Synctex

  • In a script called 'vimura':
#!/bin/sh
echo $1
zathura -s -x "gvim --servername $1 -c \"let g:syncpdf='$1'\" --remote +%{line} %{input}" $*
@dseeni
dseeni / autocommands.vim
Created March 14, 2020 20:54 — forked from jdhao/autocommands.vim
My Neovim configurations for both terminal and gui (using nvim-qt). Repo: https://github.com/jdhao/nvim-config
"{ Auto commands
" Do not use smart case in command line mode,
" extracted from https://goo.gl/vCTYdK
augroup dynamic_smartcase
autocmd!
autocmd CmdLineEnter : set nosmartcase
autocmd CmdLineLeave : set smartcase
augroup END
" Set textwidth for text file types