This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo 'This script checks the HIBP API to see if a password has been breached.' | |
echo 'Only the first 5 characters of the SHA1 hash of the password leave the device.' | |
echo | |
echo -n 'Password: ' | |
read -s password | |
hash=$(echo -n "$password" | sha1sum | cut -c 1-40) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$.get('/users/daily-site-access/' + StackExchange.options.user.userId, t => { | |
eval(t.match(/var visited = {.+};/)[0]); | |
const firstYear = Object.keys(visited)[0], | |
firstMonth = Object.keys(visited[firstYear])[0], | |
firstDay = Object.keys(visited[firstYear][firstMonth])[0], | |
date = new Date(firstYear, firstMonth - 1, firstDay), | |
today = Date.now(); | |
let days = [], seq = 0, streaks = [0], fewest = 100, fewestDate; | |
do { | |
days[++seq] = !!visited[date.getFullYear()][date.getMonth() + 1][date.getDate()]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const config = { | |
'[email protected]': { | |
prefix: 'Source', | |
color: CalendarApp.EventColor.PALE_RED, | |
visibility: 'private' | |
}, | |
}; | |
function onCalendarChanged(trigger) { | |
copyEvents(trigger.calendarId); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$headers = [ | |
"Content-Security-Policy: style-src 'self'", | |
"Content-Type: application/json", | |
]; | |
foreach ($headers as $header) { | |
header($header); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript:(function (doc) { | |
let cards = { | |
1111: 'Card #1', | |
2222: 'Card #2', | |
}; | |
doc.querySelectorAll('[data-number]').forEach(function (card) { | |
card.parentNode.querySelector('span').innerText = cards[card.dataset.number]); | |
}); | |
})(document); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "Photos" | |
activate | |
set folderList to name of every folder | |
set selectedFolders to choose from list folderList with prompt "Select folders:" with multiple selections allowed | |
set destination to POSIX path of (choose folder with prompt "Please select a backup location:") | |
repeat with f in folders | |
if selectedFolders contains name of f then | |
my exportFolder(f, destination) | |
end if |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*.json diff=gron |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"E92000001": { | |
"country_or_area": "England", | |
"council": 0, | |
"wards": 0, | |
"postcodes": 0, | |
"full_or_partial": "F", | |
"key_points": "Your area is under Covid restrictions, in the Tier 1 (medium alert) category for England.", | |
"meeting_friends_and_family": "* You can mix socially in a group of up to six people from multiple households. This includes children and applies indoors and outdoors, including private homes. \n* Socialising in larger groups is against the law, with fines up to £6,400.\n* There are exceptions, for example if your household or support bubble is larger than six, or if someone enters your house to carry out work, registered childcare or care for a vulnerable person.\n", |
- Dancing in the Dark / All My Friends
- BBC highlights
- Foo Fighters cancelled due to Dave Grohl’s broken leg
- The Libertines (BBC highlights) moved forward
- Without this, might have missed Hot Chip
NewerOlder