Skip to content

Instantly share code, notes, and snippets.

🎱
Ask again tomorrow

Rhys lyptt

🎱
Ask again tomorrow
Block or report user

Report or block lyptt

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 SQS-S3-Trigger-Lambda-Event.json
{
"Records": [
{
"eventVersion": "2.1",
"eventSource": "aws:s3",
"awsRegion": "us-east-1",
"eventTime": "2020-05-07T08:31:33.679Z",
"eventName": "ObjectCreated:Put",
"userIdentity": {
"principalId": "A352Z9BPTSWJHH"
@lyptt
lyptt / Workflow.cs
Created May 4, 2020
ASP.NET Web API Workflows
View Workflow.cs
// The entrypoint is a Web API controller. Each method's sole responsibility is to marshal data from
// a HTTP request into a form appropriate for our business logic, and to subsequently marshal the
// result of that business logic into a HTTP response.
[ApiController]
[Route("/users")]
public class UsersController : ControllerBase {
private readonly IUsersDelegate _delegate;
public UsersController(IUsersDelegate _delegate) {
View keybase.md

Keybase proof

I hereby claim:

  • I am lyptt on github.
  • I am lyptt (https://keybase.io/lyptt) on keybase.
  • I have a public key ASCQxAr-XvfOHF8WUfHdStEyFY1iePyCl_wbLJtDK2KeTgo

To claim this, I am signing this object:

@lyptt
lyptt / add-bootstrap.js
Created Oct 10, 2018
Add bootstrap to any CSS-less page
View add-bootstrap.js
javascript:(function()%7Bdocument.body.appendChild(document.createRange().createContextualFragment(%60%3Clink%20rel%3D%22stylesheet%22%20href%3D%22https%3A%2F%2Fstackpath.bootstrapcdn.com%2Fbootstrap%2F4.1.3%2Fcss%2Fbootstrap.min.css%22%20integrity%3D%22sha384-MCw98%2FSFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO%22%20crossorigin%3D%22anonymous%22%3E%60))%3Bdocument.body.className%20%3D%20%22container%22%7D)()
View keybase.md

Keybase proof

I hereby claim:

  • I am lyptt on github.
  • I am lyptt (https://keybase.io/lyptt) on keybase.
  • I have a public key whose fingerprint is 3F04 8F32 DCE6 3B9D FDB1 9A59 B97C 55CC 49BA 7858

To claim this, I am signing this object:

View altergather.lua
--[[
::: General Task Parameters
"condition" - Table parameter listing various extra conditions required to perform this task, can be used to evaluate lua code.
"complete" - Table parameter listing various extra conditions that will cause this task to complete, can be used to evaluate lua code.
"lowpriority","normalpriority","highpriority" - affects task evaluations (advanced).
"weatherlast","weathernow","weathernext" - used to evaluate weather conditions for the "mapid" tag listed for the task.
"eorzeaminhour","eorzeamaxhour" - used to evaluate the eorzea time ranges a task is valid.
"lastshiftmin" - used to evaluate a minimun amount of time (in seconds) since last weather shift
"lastshiftmax" - used to evaluate a maximum amount of time (in seconds) since last weather shift
"nextshiftmin" - used to evaluate a minimun amount of time (in seconds) until next weather shift
View ios_keychain_itunes_backup_and_icloud_sync.md

iOS Keychain - iTunes backup vs iCloud sync

Helper guide to help understand when data gets backedup/synced

My use case: Switching from [UIDevice uniqeIdentifier] to a UUID + Keychain approach.

  • Apple no longer supports [UIDevice uniqueIdentifier] and does not allow app submission to the App store. My requirements are 1) UUID is to persist on the device ONLY 2) UUID is not to be synced or backed up across devices. 3) Works on iOS6 and up

UDID alternative availability

|Availability|iOS 2|iOS 3|iOS 4|iOS 5|iOS 6|iOS 7|iOS 8|

@lyptt
lyptt / Blockstack verification
Created Dec 25, 2017
Blockstack verification
View Blockstack verification
Verifying my Blockstack ID is secured with the address 1GmM6PXLyQ4GrrR9YpozGvB2o6brDzu8LJ https://explorer.blockstack.org/address/1GmM6PXLyQ4GrrR9YpozGvB2o6brDzu8LJ
View sepsplit.c
/*
* SEP firmware split tool
*
* Copyright (c) 2017 xerub
*/
#include <fcntl.h>
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
View auth-requests.conditions.js
import expect from 'expect'
function registerPre(username, password, firstName, lastName, dob) {
expect(username).toBeTruthy()
expect(password).toBeTruthy()
[username, password, firstName, lastName].forEach((arg) => expect(arg).toBeA(String))
expect(username.length).toBeGreaterThanOrEqualTo(1)
expect(username.length).toBeLessThanOrEqualTo(16)
expect(password.length).toBeGreaterThanOrEqualTo(6)
expect(username).toMatch(/[A-Za-z0-9]*/g)
You can’t perform that action at this time.