(This is a fork of Michael's original gist with some editing of the unions + records sections.)
Each of these examples assume the usage of --strict mode in Typescript
Can be implemented using “Custom Types”
| You are an assistant that engages in extremely thorough, self-questioning reasoning. Your approach mirrors human stream-of-consciousness thinking, characterized by continuous exploration, self-doubt, and iterative analysis. | |
| ## Core Principles | |
| 1. EXPLORATION OVER CONCLUSION | |
| - Never rush to conclusions | |
| - Keep exploring until a solution emerges naturally from the evidence | |
| - If uncertain, continue reasoning indefinitely | |
| - Question every assumption and inference |
| #!/usr/bin/env node | |
| // the .mjs extension is important | |
| // run this inside the directory containing the `elm.json` file | |
| // (if it's not executable, run `chmod +x elm-build-cache.mjs`) | |
| // with VERBOSE=1 env var it will show you results of the exec commands | |
| import fs from 'fs/promises'; | |
| import {exec} from 'child_process'; |
(This is a fork of Michael's original gist with some editing of the unions + records sections.)
Each of these examples assume the usage of --strict mode in Typescript
Can be implemented using “Custom Types”
Each of these examples assume the usage of --strict mode in Typescript
Can be implemented using “Custom Types” https://guide.elm-lang.org/types/custom_types.html
Install Haskell version 8.2.2: https://www.haskell.org/platform/prior.html
Elm will NOT build in 8.4.2.
Do once, after installing Haskell:
cabal update
Download the compiler source:
I recently had several days of extremely frustrating experiences with service workers. Here are a few things I've since learned which would have made my life much easier but which isn't particularly obvious from most of the blog posts and videos I've seen.
I'll add to this list over time – suggested additions welcome in the comments or via twitter.com/rich_harris.
Chrome 51 has some pretty wild behaviour related to console.log in service workers. Canary doesn't, and it has a load of really good service worker related stuff in devtools.
| #!/bin/bash | |
| # remove exited containers: | |
| docker ps --filter status=dead --filter status=exited -aq | xargs -r docker rm -v | |
| # remove unused images: | |
| docker images --no-trunc | grep '<none>' | awk '{ print $3 }' | xargs -r docker rmi | |
| # remove unused volumes: | |
| find '/var/lib/docker/volumes/' -mindepth 1 -maxdepth 1 -type d | grep -vFf <( |