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_pulumi_info() { | |
CONFIG_FILE_NAME="Pulumi.yaml" | |
CONTAINING_FOLDER="$(pwd)" | |
while [[ "$CONTAINING_FOLDER" != "" && ! -e "$CONTAINING_FOLDER/$CONFIG_FILE_NAME" ]]; do | |
CONTAINING_FOLDER="${CONTAINING_FOLDER%/*}" | |
done | |
YAML_FILE="${CONTAINING_FOLDER}/${CONFIG_FILE_NAME}" | |
if [[ -f "$YAML_FILE" ]]; then | |
WORKSPACE_NAME="$(cat $YAML_FILE | grep name: | head -1 | sed 's/name: //g ')" |
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
// Church numeral encoding | |
const ZERO = f => x => x | |
const increment = n => f => x => n(f)(x) | |
// do not try to understand this. This way madness lies... | |
const decrement = n => f => x => n(g => h => h(g(f)))(u => x)(u => u) | |
// we're going to keep this simple for now, but trust me that booleans are also an interface... |
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
@echo off | |
if exist running exit | |
cd /d "%userprofile%\Downloads\" | |
set channel=continuous | |
set url=https://storage.googleapis.com/chromium-browser-%channel%/Win_x64 | |
set wget=wget -N | |
type nul > running | |
if "%1" == "" ( | |
%wget% %url%/LAST_CHANGE || goto hell | |
fc LAST_CHANGE LastVersion && goto hell |
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 json | |
import os | |
import requests | |
import time | |
def write_to_file(data, **kwargs): | |
'''Writes a string to a file''' | |
global json_file_path | |
end = kwargs.pop('end', False) |
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 json | |
import os | |
import requests | |
import time | |
def write_to_file(data, **kwargs): | |
'''Writes a string to a file''' | |
global json_file_path | |
end = kwargs.pop('end', False) |