Skip to content

Instantly share code, notes, and snippets.

from dataclasses import dataclass, field
from enum import Enum
from input_utils import get_input
from intcode import Program, read_memory, run_program
from log_utils import log
from typing import List, Set
class Direction(Enum):
UP = 0
gbataille ~/Doc…infra/terraform $ TF_LOG=DEBUG ave default -- terraform init 7:51
2019/08/07 07:52:07 [INFO] Terraform version: 0.12.5
2019/08/07 07:52:07 [INFO] Go runtime version: go1.12.7
2019/08/07 07:52:07 [INFO] CLI args: []string{"/usr/local/bin/terraform", "init"}
2019/08/07 07:52:07 [DEBUG] Attempting to open CLI config file: /Users/gbataille/.terraformrc
2019/08/07 07:52:07 Loading CLI configuration from /Users/gbataille/.terraformrc
2019/08/07 07:52:07 [INFO] CLI command args: []string{"init"}
Initializing modules...
2019/08/07 07:52:07 [DEBUG] Module installer: begin ap-northeast-1_base
2019/08/07 07:52:07 [DEBUG] Module installer: begin ap-northeast-1_storage
@gbataille
gbataille / terraform.out
Created July 18, 2019 11:21
Terraform plan for Aurora RDS upgrade
Terraform will perform the following actions:
# aws_rds_cluster.main_postgresql will be updated in-place
~ resource "aws_rds_cluster" "main_postgresql" {
apply_immediately = true
arn = "arn:aws:rds:us-east-1:764058948821:cluster:aurora-cluster-main"
availability_zones = [
"us-east-1a",
"us-east-1b",
"us-east-1c",
{-# LANGUAGE OverloadedStrings #-}
module GitHUD (
githud,
githudd
) where
import Control.Concurrent (forkFinally)
import Control.Concurrent.Delay (delaySeconds)
import Control.Concurrent.MVar (MVar, readMVar, newMVar, swapMVar, takeMVar, putMVar)
module Huffman where
import Data.List
import Data.SortedList
-- A symbol and its probability
type Symbol = String
data SymbolP = SymbolP { symbol :: String
, probaS :: Float
} deriving (Show)
@startuml
start
note right
* **RT** refers to the refresh token in the request
* **RT_new** refers to the new refresh token
* **AT** refers to the Access Token that was created
at the same time as RT
* **AT_new** refers to the access token under creation
* **AT_refreshed** refers to an access token that might
already have been created from RT (but RT is still in
@startuml
start
note right
* **RT** refers to the refresh token in the request
* **RT_new** refers to the new refresh token
* **AT** refers to the Access Token that was created
at the same time as RT
* **AT_new** refers to the access token under creation
* **AT_refreshed** refers to an access token that might
already have been created from RT (but RT is still in
set -x
set -e
rt=`curl -X POST http://local.pix4d.com:8000/oauth2/token/ \
-H 'content-type: multipart/form-data' \
-F grant_type=password \
-F username=gregory.bataille@pix4d.com \
-F 'password=foobar' \
-F client_id=abc \
-F client_secret=def123 \
$( () ->
# Executes only if we are in a "question" view
if ($("#question-view").length)
var testProto = {
fun: function () { return 2;},
aString: "aString",
aSecondString: 'aSecondString',
anArray: [1, 2, 3]
},
testObject1 = $.extend({}, testProto),
testObject2 = $.extend({}, testProto),
testObject3 = $.extend(true, {}, testProto);