I hereby claim:
- I am zaccolley on github.
- I am zaccolley (https://keybase.io/zaccolley) on keybase.
- I have a public key whose fingerprint is 35DB 3451 A554 3A15 1D8E 8B72 5517 6B90 5BEC F424
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
# get latest pic, change your screen resolution in the url paths: https://unsplash.it/width/height?random | |
wget -O /tmp/wallpaper 'https://unsplash.it/1366/768?random' > /dev/null 2>&1 | |
# set it as desktop wallpaper | |
gsettings set org.gnome.desktop.background picture-uri /tmp/wallpaper # gnome ubuntu | |
# osascript -e 'tell application "Finder" to set desktop picture to POSIX file "/tmp/wallpaper"' # osx |
const { LastFmNode } = require('lastfm'); | |
const lastfm = new LastFmNode({}); | |
lastfm.stream('zaccolley').on('nowPlaying', track => { | |
console.log(track); | |
}); |
{ | |
"tracks": [ | |
{ | |
"mbid": "6d5625ba-8cdc-489d-8b5b-f298e76f8862", | |
"name": "Aubrey Plaza", | |
"artist": "Bear Cavalry", | |
"album": "Puryys", | |
"url": "https://www.last.fm/music/Bear_Calvary/_/Puryys", | |
"image": "https://lastfm-img2.akamaized.net/image.png", | |
"nowplaying": true |
const SerialPort = require('serialport') | |
const serialPort = new SerialPort('/dev/ttyUSB0', { baudrate: 19200 }) | |
const Printer = require('thermalprinter'); | |
const printer = new Printer(serialPort); | |
printer.on('ready', () => { | |
printer.printImage(imagePath).print(); | |
}); |
const gm = require('gm'); | |
gm('/path/to/inputFile.png') | |
.monochrome() | |
.write('/path/to/outputFile.png', () => { | |
// Image created | |
}); |
app.get('/', (request, response) => { | |
console.log(request.header('DNT')) | |
}) |
function isDoNotTrackEnabled (request) { | |
const doNotTrackHeader = request.header('DNT') | |
if (!doNotTrackHeader) { | |
return false | |
} | |
if (doNotTrackHeader.charAt(0) === '1') { | |
return true | |
} |
function isDoNotTrackEnabled () { | |
const doNotTrackOption = ( | |
window.doNotTrack || | |
window.navigator.doNotTrack || | |
window.navigator.msDoNotTrack | |
) | |
if (!doNotTrackOption) { | |
return false | |
} |
const trackingScripts = ` | |
<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'); | |
</script> | |
` | |
const html = ` |