Skip to content

Instantly share code, notes, and snippets.

View LukeCarrier's full-sized avatar
🇵🇭
Take me back

Luke Carrier LukeCarrier

🇵🇭
Take me back
View GitHub Profile
// Name: Pomodoro
// Description: A Pomodoro timer, right here!
import "@johnlindquist/kit";
const HOUR_MIN = 60;
const MIN_SEC = 60;
const SEC_MS = 1000;
const WORK_INTERVAL_SECS = 25 * 60;
@LukeCarrier
LukeCarrier / keybase.md
Created June 5, 2021 14:17
Keybase proof

Keybase proof

I hereby claim:

  • I am LukeCarrier on github.
  • I am lukecarrier (https://keybase.io/lukecarrier) on keybase.
  • I have a public key whose fingerprint is FF41 0350 599A A262 D4E9 ABFA A0BF E238 A026 9C9B

To claim this, I am signing this object:

@LukeCarrier
LukeCarrier / README.md
Last active May 12, 2020 23:02
West Mercia Police teams, retrieved from the Community Messaging Service

West Mercia Police teams, retrieved from the Community Messaging Service

A crude hack to quickly (ish) pull policing team data from the West Mercia Police Community Messaging Service.


Here be dragons

This is ugly, as the data comes from (fairly well templated) web pages, but which lack any clear semantic meaning. We should really do the whole semantic web thing.

@LukeCarrier
LukeCarrier / idtool.sh
Last active September 27, 2019 11:28
uid/gid tool
#!/bin/bash
# Change user uids and group gids, preserving file permissions on all mounted
# volumes.
change_user_uid() {
if (( $# != 2 )); then
echo "${0}: usage: ${0} USERNAME NEW_UID" >&2
return 1
fi
@LukeCarrier
LukeCarrier / diff-db.ps1
Created November 28, 2018 12:03
Diff your SQL Server databases
Import-Module -Name SqlServer
function Import-AvadoSqlServerManagementObjects()
{
$assemblies = @(
"Microsoft.SqlServer.Management.Common",
"Microsoft.SqlServer.Smo",
"Microsoft.SqlServer.Dmf ",
"Microsoft.SqlServer.Instapi ",
"Microsoft.SqlServer.SqlWmiManagement ",
param(
[SecureString] $SafeModeAdministratorPassword = (ConvertTo-SecureString -String 'P4$$word' -AsPlainText -Force),
[string] $DomainName = 'adds.localdev',
[string] $DomainNetbiosName = 'ADDSLOCALDEV',
[string] $DomainSuffix = 'DC=adds,DC=localdev',
[string] $UserName = 'Luke.Carrier',
[string] $UserFullName = 'Luke Carrier',
[SecureString] $UserPassword = (ConvertTo-SecureString -String 'P4$$word' -AsPlainText -Force),
<?php // ~/.local/share/psysh/Commands/MoodleMeUpCommand.php
namespace LukeCarrier\Psysh\Commands;
use Psy\Command\Command;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
class MoodleMeUpCommand extends Command {
protected function configure() {