-
Install https://github.com/sindresorhus/dark-mode
$ brew install dark-mode
-
Download
iterm_profile.zsh
This file contains hidden or 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
const PREFIX_TYPES: &[&str] = &["Compiling", "Downloading", "Fetching", "Printing", "Doing"]; | |
const fn max_prefix_width() -> usize { | |
let mut max_width = 0; | |
let mut i = 0; | |
loop { | |
if i == PREFIX_TYPES.len() { | |
break; | |
} |
This file contains hidden or 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
kitty_reload() { | |
DARK_MODE="$(dark-mode status)" | |
# check if kitty is active | |
if [[ -n "$KITTY_PID" ]]; then | |
# set dark theme | |
if [[ "$DARK_MODE" == "on" ]]; then | |
kitty @ set-colors --all --configured "$HOME/.config/kitty/theme-dark.conf" | |
else | |
kitty @ set-colors --all --configured "$HOME/.config/kitty/theme-light.conf" |
This file contains hidden or 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
use std::ops::{Add, RangeInclusive}; | |
struct Collate<Iter, Item> { | |
iter: Iter, | |
current: Option<RangeInclusive<Item>>, | |
} | |
impl<Iter, Item> Collate<Iter, Item> { | |
fn new(iter: Iter) -> Self { | |
Self { |
This file contains hidden or 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
[829/3950] Compiling C++ object libcommon.fa.p/disas_libvixl_vixl_a64_disasm-a64.cc.o | |
FAILED: libcommon.fa.p/disas_libvixl_vixl_a64_disasm-a64.cc.o | |
c++ -Ilibcommon.fa.p -I. -I.. -I../dtc/libfdt -I../capstone/include/capstone -Iqapi -Itrace -Iui -Iui/shader -I/usr/local/Cellar/gnutls/3.6.15/include -I/usr/local/Cellar/nettle/3.7.2/include -I/usr/local/Cellar/libtasn1/4.16.0_1/include -I/usr/local/Cellar/libidn2/2.3.0/include -I/usr/local/Cellar/p11-kit/0.23.22/include/p11-kit-1 -I/usr/local/Cellar/libffi/3.3_3/include -I/usr/local/Cellar/glib/2.68.1/include -I/usr/local/Cellar/glib/2.68.1/include/glib-2.0 -I/usr/local/Cellar/glib/2.68.1/lib/glib-2.0/include -I/usr/local/opt/gettext/include -I/usr/local/Cellar/pcre/8.44/include -I/usr/local/Cellar/glib/2.68.1/include/gio-unix-2.0 -I/usr/local/Cellar/jpeg/9d/include -I/usr/local/Cellar/libusb/1.0.24/include/libusb-1.0 -I/usr/local/Cellar/libslirp/4.4.0_1/include/slirp -I/usr/local/Cellar/libpng/1.6.37/include/libpng16 -I/usr/local/Cellar/pixman/0.40.0/include/pi |
This file contains hidden or 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
$ cargo build | |
error: reached the recursion limit while instantiating `<FreeFamily<ToyFamily<char>> as ...osure@src/free.rs:53:88: 53:96]>` | |
--> src/free.rs:53:75 | |
| | |
53 | Free::Free(box fa) => Free::Free(Box::new(self.0.fmap(fa, |x| self.bind(x, |a| f(a))))), | |
| ^^^^^^^^^^^^^^^^^^^^^^ | |
| | |
note: `<FreeFamily<F> as Monad>::bind` defined here | |
--> src/free.rs:47:5 | |
| |
This file contains hidden or 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
newtype ZIO r a | |
= ZIO (ReaderT r IO a) | |
deriving newtype (Functor, Applicative, Monad, MonadIO) | |
unZIO :: ZIO r a -> ReaderT r IO a | |
unZIO (ZIO z) = z | |
runZIO :: ZIO r a -> (r | r1) -> IO a | |
runZIO (ZIO z) r = runReaderT z r |
This file contains hidden or 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
type TestRes = RouteResult< | |
Created<JsonValue>, | |
Coprod!( | |
BadRequest<JsonValue>, | |
NotFound<JsonValue>, | |
InternalServerError<JsonValue> | |
), | |
>; | |
#[post("/test/<a>")] |
This file contains hidden or 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
{-# LANGUAGE DeriveGeneric | |
, DefaultSignatures | |
, FlexibleInstances | |
, FlexibleContexts | |
, KindSignatures | |
, DataKinds | |
, TypeOperators | |
, DeriveAnyClass | |
, ScopedTypeVariables #-} |
NewerOlder