Skip to content

Instantly share code, notes, and snippets.

Avatar

Taylor buley

  • McNaughton Newspapers, Inc.
  • Winters, California
View GitHub Profile
@buley
buley / gist:f93a5e9fcf4a47a539a4e2b90c67b324
Created Jan 28, 2019
Readability - docs example fixed
View gist:f93a5e9fcf4a47a539a4e2b90c67b324
var Readability = require('Readability');
var JSDOM = require('jsdom').JSDOM;
var doc = new JSDOM("<body>Here's a bunch of text</body>", {
url: "https://www.example.com/the-page-i-got-the-source-from",
});
let reader = new Readability(doc.window.document);
let article = reader.parse();
console.log(article);
View gist:6fe57bca09d8c469425b771866633021
var Readability = require('Readability');
var JSDOM = require('jsdom').JSDOM;
var doc = new JSDOM("<body>Here's a bunch of text</body>", {
url: "https://www.example.com/the-page-i-got-the-source-from",
});
let reader = new Readability(doc);
let article = reader.parse();
View simple javascript redirect
<script>
window.location = '{publish_url}';
</script>
View gist:a70b0098df3701b1b168a8e45abdea03
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republic_spec.app/Settings.bundle/en.lproj/Root.strings
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republic_spec.app/FacebookSDKStrings.bundle/Resources/af.lproj/FacebookSDK.strings
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republic_spec.app/FacebookSDKStrings.bundle/Resources/ar.lproj/FacebookSDK.strings
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republic_spec.app/FacebookSDKStrings.bundle/Resources/bn.lproj/FacebookSDK.strings
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republic_spec.app/FacebookSDKStrings.bundle/Resources/cs.lproj/FacebookSDK.strings
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republic_spec.app/FacebookSDKStrings.bundle/Resources/da.lproj/FacebookSDK.strings
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republic_spec.app/FacebookSDKStrings.bundle/Resources/de.lproj/FacebookSDK.strings
Compile ./build/iPhoneSimulator-10.0-Development/Daily Republ
View gist:0a4c983376dfaf1a4d15ea837bc6e86b
<!-- Google Tag Manager -->
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
})(window,document,'script','dataLayer','GTM-TGG362C');</script>
<!-- End Google Tag Manager -->
View gist:2efde43063d6c76dfca9bc62fda2be74
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-59091437-1', 'auto');
ga('send', 'pageview');
</script>
View gist:fdbce8722dec2dcff947693b11c4d88e
.navheaderleft {
background-color: #eee;
color: #000;
border-radius: 15px;
padding: 5px 20px 5px 20px;
}
.navheaderright {
background-color: #eee;
color: #000;
View gist:7681fedaff8e435b9ca7d9c9fd52d028
[~] cat /tmp/ha.txt|grep -vi '^$'|sort -dbfi|uniq -c|sort -nr
15 freelance
5 Mic
4 The Daily Dot
3 Bustle
2 Vice
2 The Huffington Post
2 The Guardian
2 The Frisky
2 Refinery 29
View gist:e5fe901d80c7a62b15206d703a781b5b
Sacramentio Police and Fire Frequencies
SACRAMENTO COUNTY SHERIFF
Channel 1 Ch1 North patrol/STAR 453.900
Channel 2 Ch2 Records/tactical 453.250
Channel 3 Ch3 South patrol 453.575
Channel 4 Ch4 Long range tac 453.675
Channel 5 Ch5 Short range tac 453.475
Channel 6 Tactical (simplex) 453.950
View gist:c3a42173ff4c554045c437f7c74e5d94
[systems] traceroute bad.horse staging ✭
traceroute to bad.horse (162.252.205.157), 64 hops max, 52 byte packets
1 192.168.1.1 (192.168.1.1) 1.759 ms 0.797 ms 1.722 ms
2 10.0.0.1 (10.0.0.1) 12.908 ms 0.977 ms 0.815 ms
3 96.120.14.41 (96.120.14.41) 8.866 ms 8.242 ms 9.106 ms
4 xe-1-1-3-sur01.davis.ca.ccal.comcast.net (68.87.201.29) 8.959 ms 9.668 ms 9.041 ms
5 ae-32-ar01.sacramento.ca.ccal.comcast.net (68.87.200.109) 10.813 ms 9.939 ms 10.304 ms
6 68.86.93.25 (68.86.93.25) 13.931 ms 26.853 ms 11.255 ms
7 be-7922-ar01.sandy.ut.utah.comcast.net (68.86.90.146) 29.895 ms 30.097 ms 30.129 ms
8 hu-0-4-0-1-sur04.saltlakecity.ut.utah.comcast.net (162.151.49.146) 30.544 ms