Skip to content

Instantly share code, notes, and snippets.

View RyanTG's full-sized avatar

Ryan TG RyanTG

View GitHub Profile
@RyanTG
RyanTG / PVR.rb
Created August 4, 2022 04:45
Max overlapping ranges
#!/usr/bin/env ruby
require 'csv'
require 'time'
class PeakVehicleReq
def initialize(filename)
@filename = 'Trips.csv'
end
@RyanTG
RyanTG / pbm-top20.txt
Created January 17, 2020 22:33
01/17/20 - Places on Pinball Map with the most machines. Top 20
select name,street,city,state,country,count(distinct x.machine_id) from locations l inner join location_machine_xrefs x on x.location_id=l.id group by 1,2,3,4,5 order by 6 desc limit 20;
name | street | city | state | country | count
----------------------------------------------------------------------+---------------------------------------------------------+-------------------+------------------+---------+-------
Pinball Perfection | 231 Perry Highway | Westview | PA | US | 284
Pinball Hall of Fame | 1610 E Tropicana Ave | Las Vegas | NV | US | 204
Pinball PA/Pennsylvania Coin Operated Gaming Hall of Fame and Museum | 2284 Brodhead Road, Suit
# Lines configured by zsh-newuser-install
HISTFILE=~/.histfile
HISTSIZE=5000
SAVEHIST=5000
unsetopt beep
bindkey -v
bindkey "^[[A" history-search-backward
bindkey "^[[B" history-search-forward
# End of lines configured by zsh-newuser-install
# --- special colors ---
[Background]
Color=42,33,28
[BackgroundIntense]
Color=42,33,28
[Foreground]
Color=189,174,157
[ColorEffects:Disabled]
Color=56,56,56
ColorAmount=0
ColorEffect=0
ContrastAmount=0.65
ContrastEffect=1
IntensityAmount=0.1
IntensityEffect=2
[ColorEffects:Inactive]
Do you want to clone the boot loader (executable code area, the first 446 bytes) to: sdc ?
[Y/n]
The first partition of disk /dev/sda starts at 2048.
Saving the hidden data between MBR (1st sector, i.e. 512 bytes) and 1st partition, which might be useful for some recovery tool, by:
dd if=/dev/sda of=/tmp/ocs_onthefly_local.0NPhFl/src-hidden-data.img skip=1 bs=512 count=2047
2047+0 records in
2047+0 records out
1048064 bytes (1.0 MB, 1.0 MiB) copied, 0.143125 s, 7.3 MB/s
*****************************************************.
Collecting partition /dev/sda1 info...
2018-08-01T16:41:28.938512+00:00 app[web.1]: [f552bb69-a9ba-401a-b3ed-07e9edaeb1fa] LocationMachineXref Load (19.1ms) SELECT "location_machine_xrefs".* FROM "location_machine_xrefs" WHERE "location_machine_xrefs"."location_id" IN ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17, $18, $19, $20, $21, $22, $23, $24, $25, $26, $27, $28, $29, $30, $31, $32, $33, $34, $35, $36, $37, $38, $39, $40, $41, $42, $43, $44, $45, $46, $47, $48, $49, $50, $51, $52, $53, $54, $55, $56, $57, $58, $59, $60, $61, $62, $63, $64, $65, $66, $67, $68, $69, $70, $71, $72, $73, $74, $75, $76, $77, $78, $79, $80, $81, $82, $83, $84, $85, $86, $87, $88, $89, $90, $91, $92, $93, $94, $95, $96, $97, $98, $99, $100, $101, $102, $103, $104, $105, $106, $107, $108, $109, $110, $111, $112, $113, $114, $115, $116, $117, $118, $119, $120, $121, $122, $123, $124, $125, $126, $127, $128, $129, $130, $131, $132, $133, $134, $135, $136, $137, $138, $139, $140, $141, $142, $143, $144, $145, $146, $147, $148, $149, $150
Name Ipdb link Year Manufacturer Ipdb Opdb Id [Machine group] Name [Machine group] Created at [Machine group] Updated at [Machine group]
SlugFest http://ipdb.org/machine.cgi?id=3281 1991 Williams 3281 -
Little League http://ipdb.org/machine.cgi?id=3213 1966 Midway 3213 -
Galactic Girl http://ipdb.org/machine.cgi?id=5559 2010 Custom 5559 -
Ticket Tac Toe http://ipdb.org/machine.cgi?id=4334 1996 Williams 4334 -
Bumper http://ipdb.org/machine.cgi?id=405 1936 Bally 405 -
Hot-Rods http://ipdb.org/machine.cgi?id=1246 1949 Bally 1246 -
Beauty Contest http://ipdb.org/machine.cgi?id=217 1960 Bally 217 -
St. Moritz http://ipdb.org/machine.cgi?id=2410 1938 Chicago Coin 2410 -
Super Mario Bros. Mushroom World http://ipdb.org/machine.cgi?id=3427 1992 Gottlieb 3427 -
@RyanTG
RyanTG / browntown.txt
Last active January 8, 2018 05:22
Browntown Color Scheme
[ColorEffects:Disabled]
Color=56,56,56
ColorAmount=0
ColorEffect=0
ContrastAmount=0.65
ContrastEffect=1
IntensityAmount=0.1
IntensityEffect=2
[ColorEffects:Inactive]
@RyanTG
RyanTG / log.txt
Created November 8, 2017 04:50
starting log
11-07 20:48:58.770 5057-5057/? D/Launcher: DragLayer dispatchTouchEvent: ACTION_DOWN
11-07 20:48:58.971 4221-4221/? D/wpa_supplicant: wlan0: Control interface command 'SIGNAL_POLL'
11-07 20:48:58.985 4221-4221/? D/wpa_supplicant: CTRL-DEBUG: global_ctrl_sock-sendto: sock=11 sndbuf=163840 outq=0 send_len=48
11-07 20:48:59.378 5057-5057/? D/Launcher: startAnimationToWorkspace: fromState=APPS, toState=SPRING_LOADED
11-07 20:48:59.710 5057-5057/? D/Launcher: onPageSwitch: newPageIndex=1, hasCustomContent=true
11-07 20:49:00.000 2517-4079/? V/AlarmManager: Triggering alarm #0: Alarm{9cf38a3 type 3 when 83343871 android}operation =Intent { act=android.intent.action.TIME_TICK flg=0x50000000 }
11-07 20:49:00.002 2517-2517/? V/AlarmManager: set(PendingIntent{bada69a: PendingIntentRecord{6cf0bcb android broadcastIntent}}) : type=3 triggerAtTime=83403871 win=0 tElapsed=83403871 maxElapsed=83403871 interval=0 flags=0x1
11-07 20:49:00.200 5057-5057/? D/Launcher: DragLayer dispatchTouchEvent: ACTION_UP
11-07 20:49:00.297 2