Skip to content

Instantly share code, notes, and snippets.

"""
GitHub doesn't currently support updating all comments made on one account
to be made by another account. I made a lot of comments with my work
account, and people keep tagging my work account on issues, but I'd like
them to start referencing my personal account.
So for now, I'll just get every comment I made on my work account and add
a blurb to the beginning about using my personal account.
Run with:
Build with the following command:
```bash
hadrian/build -j9 --freeze1
```
Then
```
GHC=/path/to/repo/_build/stage1/bin/ghc ./run.py
```
Note: `--flavour=perf` and `--flavour=bench` weren't working for me on my M2 Mac.
@brandonchinn178
brandonchinn178 / stack-5772-verbose-output
Created July 7, 2022 03:06
Stack --verbose output for #5772
$ stack test --verbose
Version 2.7.5, Git revision ba147e6f59b2da75b1beb98b1888cce97f7032b1 x86_64 hpack-0.34.4
2022-07-06 20:03:02.131752: [debug] Checking for project config at: /Users/brandino/Desktop/foo/stack.yaml
2022-07-06 20:03:02.132766: [debug] Loading project config file stack.yaml
2022-07-06 20:03:02.143454: [debug] (SQL) SELECT COUNT(*) FROM "last_performed" WHERE ("action"=?) AND ("timestamp">=?); [PersistInt64 1,PersistUTCTime 2022-07-06 03:03:02.143421 UTC]
2022-07-06 20:03:02.144469: [debug] Using package location completions from a lock file
2022-07-06 20:03:02.148035: [debug] Loaded snapshot from Pantry database.
2022-07-06 20:03:02.298575: [debug] RawSnapshotLayer {rslParent = RSLCompiler (WCGhc (mkVersion [9,0,2])), rslCompiler = Nothing, rslLocations = [RPLIHackage AC-Angle-1.0@sha256:e1ffee97819283b714598b947de323254e368f6ae7d4db1d3618fa933f80f065,544 (Just (TreeKey 7edd1f1a6228af27c0f0ae53e73468c1d7ac26166f2cb386962db7ff021a2714,210)),RPLIHackage ALUT-2.4.0.3@sha256:ab8c2af4c13bc04c7f
@brandonchinn178
brandonchinn178 / ihaskell
Last active August 14, 2022 02:17
IHaskell in Docker
#!/usr/bin/env python3
"""Run IHaskell with Docker."""
import argparse
import json
import subprocess
import sys
import webbrowser
from pathlib import Path
Repro for https://github.com/styled-components/babel-plugin-styled-components/issues/343
1. `mkdir repro && cd repro`
1. Copy these files into directory
1. `yarn set version berry`
1. `yarn`
1. `yarn jest`: runs with `babel-jest`, works
1. `USE_TS_JEST=1 yarn jest`: runs with `ts-jest`, fails
data Digit = Zero | One | Two | Three | Four | Five | Six | Seven | Eight | Nine
deriving (Enum)
zero, one, ten :: Int
zero = fromEnum Zero
one = fromEnum One
ten = succ $ fromEnum Nine
main :: IO ()
main = mapM_ print [one .. ten * ten]
@brandonchinn178
brandonchinn178 / ContextMenu.vue
Last active October 25, 2017 03:08
Vue Context Menu custom block
<template>
<ul
v-if="!cmHide"
v-on-click-outside="hide"
class="context-menu"
:style="position"
>
<slot></slot>
</ul>
</template>