Skip to content

Instantly share code, notes, and snippets.

View SeanFelipe's full-sized avatar

SeanFelipe

View GitHub Profile
@SeanFelipe
SeanFelipe / pre_git_checks
Last active August 13, 2021 16:18
pre-commit script
#!/usr/bin/env ruby
require 'paint/pa'
pa "running pre git checks from #{Dir.pwd}/pre_git_checks ...", :gray
class DeleteCodeError < RuntimeError; end
def ags(tag)
#res = `unbuffer ag #{tag}`
res = `ag #{tag}`
https://zephyrdocs.atlassian.net/wiki/spaces/ZE/pages/1558445671/Zephyr+REST+API
import pytest
from selenium import webdriver
from pdb import set_trace
from poms_google import *
from html.parser import HTMLParser
class HP(HTMLParser):
def handle_starttag(self, tag, attrs):
#print("start tag: ", tag, attrs)
@SeanFelipe
SeanFelipe / ha_appts.py
Created March 21, 2021 21:24
for care.coach, 21 Mar 2021 Sean Wolfe
from pdb import set_trace
activity = [
(1, '@login', None),
(5, '@startVideo', 'Bob'),
(20, '@startVideo', 'Thomas'),
(66, '@stopVideo', 'Thomas'),
(70, '@startVideo', 'Lily'),
(75, '@stopVideo', 'Bob'),
(78, '@stopVideo', 'Lily'),
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.common.keys import Keys
from pyte_prism import Page, Element, Elements
from pdb import set_trace
#from pyte_prism import PageSection, PageIframe, Element, Section, Sections, Iframe
# Page must inherit Page class
class GoogleHome(Page):
_url = "http://google.com/"
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required
=begin
I needed a few more minutes to run an optimization on the hacker rank exercise.
Problem: supply an array arr, such that:
- We sum each element in the array in sequence
- During the operation, the current total never drops below 1
- What is the minimum starting value for a given array?
=end
def min_sum(arr)
import pygame
from pygame.transform import scale2x
screen = pygame.display.set_mode((640,480))
spritesheet = pygame.image.load('spritesheet.png')
pacman_right = scale2x(spritesheet.subsurface(455, 0, 16, 16))
pacman_left = scale2x(spritesheet.subsurface(455, 16, 16, 16))
pacman_up = scale2x(spritesheet.subsurface(455, 32, 16, 16))
pacman_down = scale2x(spritesheet.subsurface(455, 48, 16, 16))