Skip to content

Instantly share code, notes, and snippets.

View amadeus's full-sized avatar
🕶️
out here livin

Amadeus Demarzi amadeus

🕶️
out here livin
View GitHub Profile
#!/bin/bash
make clean
make distclean
# ./configure --with-features=huge --enable-terminal --enable-rubyinterp --enable-python3interp --enable-perlinterp --enable-cscope
./configure --with-features=huge --enable-terminal --enable-rubyinterp --enable-python3interp --enable-perlinterp --enable-cscope --enable-luainterp=yes --with-lua-prefix=/usr/local/Cellar/lua/5.3.5_1
make
rm src/MacVim/build/Release/MacVim.app/Contents/Resources/MacVim.icns
cp ./MacVim.icns src/MacVim/build/Release/MacVim.app/Contents/Resources/
open src/MacVim/build/Release
// Default export
// Export from file.js
const ExampleSomething = {};
export default ExampleSomething;
// import from another.js
import ExampleSomething from './file.js';
// Named Exports
// Export from file.js
export const Another = {};

Fixing Windows Wake Timers

  • Download psexec
  • From Command Prompt in administrator mode (right click from search launcher)
  • Useful link Windows Timers Bullshits
  • To view current powercfg -waketimers
  • psexec.exe -i -s %windir%\system32\mmc.exe /s taskschd.msc
    • Brings up a funky UI to fix some waketimers
    • Event Viewer (Local) -> Windows Logs -> System (Right click -> Filter Current Log) -> Event sources: Power-Troubleshooter -> Ok
" Base .vimrc file
if has('vim_starting')
set nocompatible
endif
" Ensure all directories are setup properly and download plug.vim
if empty(glob('~/.vim/autoload/plug.vim'))
execute '!mkdir -p ~/.vim/bundle ~/.vim/backup ~/.vim/swap ~/.vim/cache ~/.vim/undo ~/.vim/autoload ~/.vim/bundle'
execute '!curl -fLo ~/.vim/autoload/plug.vim https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
@amadeus
amadeus / prettier.json
Last active September 9, 2022 20:03
.prettierrc template
{
"printWidth": 120,
"trailingComma": "es5",
"bracketSpacing": false,
"singleQuote": true,
"bracketSameLine": true,
"overrides": [
{
"files": ["*.css", "*.styl"],
"options": {
@amadeus
amadeus / lvimrc.vim
Last active December 23, 2019 20:49
.lvimrc template
" NOTE: Only source this file once per session
if g:localvimrc_sourced_once
finish
endif
echom '{page} .lvimrc has been sourced'
set tabstop=2
set shiftwidth=2
set expandtab
@amadeus
amadeus / mvim
Created December 3, 2018 02:09
#!/bin/sh
#
# This shell script passes all its arguments to the binary inside the
# MacVim.app application bundle. If you make links to this script as view,
# gvim, etc., then it will peek at the name used to call it and set options
# appropriately.
#
# Based on a script by Wout Mertens and suggestions from Laurent Bihanic. This
# version is the fault of Benji Fisher, 16 May 2005 (with modifications by Nico
# Weber and Bjorn Winckler, Aug 13 2007).
@amadeus
amadeus / vimrc.vim
Last active November 2, 2017 23:19
let g:hl_was_on = 0
function! ToggleHLSearch(enter)
if a:enter == 1 && v:hlsearch == 1
let g:hl_was_on = 1
elseif a:enter == 1
let g:hl_was_on = 0
set hlsearch
elseif a:enter == 0 && g:hl_was_on == 0
let g:hl_was_on = 0
set nohlsearch

Search TODOs

Quickly off the top of my head, these are the things that could use improvement. There are probably things I am forgetting and feedback from internal people as well that I am forgetting or has yet to be mentioned to me.

Jake Priority

  • AB Testing requirements
  • Backend support for
  • has:link
function bar(x: string, y: number): string {
return x.length * y;
}
type PermissionOverwrite = {
id: string;
type: 'role' | 'member',
allow: number;
deny: number;
}