Skip to content

Instantly share code, notes, and snippets.

View LBRapid's full-sized avatar
🏠
Working from home

John Dyer LBRapid

🏠
Working from home
View GitHub Profile
@LBRapid
LBRapid / autoexec.cfg
Created March 18, 2023 09:05
New CSGO autoexec
// budi's CS:GO config
// Competitive HUD from http://www.spddl.de/csgo/hud/competitivehud
// Rates
rate "128000"
cl_cmdrate "128"
cl_updaterate "128"
cl_interp "0.0"
cl_interp_ratio "1"
cl_lagcompensation "1"
class ClipartDiagnoser
def call
CSV.open("/u01/app/jsLab_server/current/tmp/clipart_designs.csv", "wb") do |csv|
csv << ["design_id"]
Design.where(updated_at: (Time.now - 24.hours)..Time.now).find_each do |design|
xml = Nokogiri::XML(design.content)
clipart = xml.xpath("//icon[@grayscale='none' and @type='IMAGE']")
if clipart.present?
class Something
attr_accessor :groups
def initialize
@groups = []
end
def respond_to_missing?(method_sym, include_private = false)
@groups.map(&:name).detect { |name| name == method_sym.to_s }
end
require 'capybara_helper'
class LabPrintSaveTest < ActionDispatch::IntegrationTest
it 'save a design through print' do
stub_rack_proxy
insert_cassette 'capybara_lab_print_save'
visit_empty_lab
click_link 'add text'
require 'capybara_helper'
class LabPrintSaveTest < ActionDispatch::IntegrationTest
it 'save a design through print' do
stub_rack_proxy
insert_cassette 'capybara_lab_print_save'
visit_empty_lab
click_link 'add text'
IGNORED = [
/The "fb-root" div has not been created/,
/Unsafe JavaScript attempt to access frame/,
/in the list of allowed domains for kit/
].freeze
@LBRapid
LBRapid / .cvimrc
Last active January 29, 2016 23:48
My cVimrc File
" Settings
set hud
set nosmoothscroll
set noautofocus " The opposite of autofocus; this setting stops
" sites from focusing on an input box when they load
set typelinkhints
let searchlimit = 30
let scrollstep = 70
let barposition = "bottom"
set nocncpcompletion
1
2
3
4
5
@LBRapid
LBRapid / autoexec.cfg
Last active September 9, 2017 07:09
CSGO
// budi's CS:GO config
// Competitive HUD from http://www.spddl.de/csgo/hud/competitivehud
// Rates
rate "128000"
cl_cmdrate "128"
cl_updaterate "128"
cl_interp "0.0"
cl_interp_ratio "1"
cl_lagcompensation "1"
# fshow - git commit browser
fshow() {
local out sha q
while out=$(
git log --decorate=short --graph --oneline --color=always |
fzf --ansi --multi --no-sort --reverse --query="$q" --print-query); do
q=$(head -1 <<< "$out")
while read sha; do
[ -n "$sha" ] && git show --color=always $sha | less -R
done < <(sed '1d;s/^[^a-z0-9]*//;/^$/d' <<< "$out" | awk '{print $1}')