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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Privacy Policy for "Eleventh Hour" App</title> | |
</head> | |
<body> | |
<h1>Privacy Policy for "Eleventh Hour" App</h1> | |
<p><strong>Last Updated:</strong> 9th August 2023</p> |
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
// See https://aka.ms/new-console-template for more information | |
using System.Text; | |
using Confluent.Kafka; | |
class Program | |
{ | |
class ByteArraySerializer : ISerializer<byte[]> | |
{ | |
public byte[] Serialize(byte[] data, SerializationContext context) |
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
locals { | |
key_attributes = [ | |
for k in [var.hash_key, var.range_key] : { | |
name = k.name | |
type = k.type | |
} if k != null | |
] | |
gsi_attributes = flatten([ | |
for gi in var.global_secondary_indexes : [ | |
for k in [gi.hash_key, gi.range_key] : { |
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
aws glue get-tables --database-name lyne --max-results 100 \ | |
| jq '.TableList[].Name' \ | |
| tr '\n' ' ' \ | |
| xargs -I {} echo "aws glue batch-delete-table --database-name lyne --tables-to-delete {}" \ | |
| sh - |
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
version: 2.1 | |
description: Publish Infrastructure with terragrunt | |
orbs: | |
terragrunt: | |
commands: | |
plan: | |
parameters: | |
target_dir: | |
type: string |
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
package yfp.io | |
import cats.effect.IO | |
import cats.MonadError | |
import cats.implicits._ | |
import yfp.ContravariantKleisli | |
import scala.util.Try | |
trait Persistence { |
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
package com.trizzle | |
import cats.effect.IO | |
import cats.implicits._ | |
import cats.{Applicative, Monad, MonadError} | |
import org.http4s.{Response, Status} | |
// Error ADT | |
sealed trait InvalidTopupReason | |
case object InvalidAmount extends InvalidTopupReason |
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
import akka.Done | |
import akka.stream.stage.{AbstractInHandler, GraphStage, GraphStageLogic} | |
import akka.stream.{Attributes, Inlet, SinkShape} | |
import com.amazonaws.services.dynamodbv2.AmazonDynamoDBAsync | |
import com.amazonaws.services.dynamodbv2.model.{BatchWriteItemRequest, PutRequest, WriteRequest} | |
import com.gu.scanamo.{DynamoFormat, Table} | |
import scala.collection.JavaConverters._ | |
import scala.concurrent.Future |
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
// The expression problem is a new name for an old problem. The goal is to | |
// define a datatype by cases, where one can add new cases to the datatype and | |
// new functions over the datatype, without recompiling existing code, and while | |
// retaining static type safety (e.g., no casts). | |
// (Philip Wadler) | |
import scala.language.implicitConversions | |
object ExpressionProblem extends App { |
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
using System; | |
using System.Reflection; | |
using System.Threading.Tasks; | |
namespace TaskMonad | |
{ | |
public static class TaskMonad | |
{ | |
public static Task<B> Select<A, B>(this Task<A> task, Func<A, B> f) => task.ContinueWith(t => t.IsCompleted ? f(t.Result) : throw t.Exception); |
NewerOlder