Skip to content

Instantly share code, notes, and snippets.

(function() {
/* This function forces rustdoc to collapse documentation for all items,
except for the methods defined in an impl block and the primary type's
declaration. This is the most natural view IMO, since it provides the
primary type along with an easy to scan overview of available methods.
rustdoc does seemingly have user settings that purport to make this the
default, but I could never cause them to work in a reliably consistent
way. This is especially useful when writing documents, where you commonly
want to refresh and look at the docs for the specific item you're working
function flatten(array) {
let i = 0;
while (i < array.length) {
if (!Array.isArray(array[i])) {
i++
} else {
array.splice(i, 1, ...array[i])
}
}
}
@rofrol
rofrol / Explain Monad using Elm.md
Last active March 25, 2020 01:40
Explain Monad using Elm - WIP
@rofrol
rofrol / Green.Book.2018.2160p.UHD.BluRay.X265-IAMABLE.srt.diff
Created May 19, 2019 11:56
Changes to original Green.Book.2018.2160p.UHD.BluRay.X265-IAMABLE.srt
```diff
diff --git a/Green.Book.2018.2160p.UHD.BluRay.X265-IAMABLE.srt b/Green.Book.2018.2160p.UHD.BluRay.X265-IAMABLE.srt
index 11a1f37..19cc58e 100644
--- a/Green.Book.2018.2160p.UHD.BluRay.X265-IAMABLE.srt
+++ b/Green.Book.2018.2160p.UHD.BluRay.X265-IAMABLE.srt
@@ -1,4 +1,4 @@
-1
+1
00:01:22,886 --> 00:01:27,734
Witaj Nowy Jorku! Jestem Bobby Rydell
@rofrol
rofrol / migration_from_actix-web-0.7.19_to_1.0.0-beta.5.md
Created May 17, 2019 16:28
migration_from_actix-web-0.7.19_to_1.0.0-beta.5.md
diff --git a/mock/server/src/main.rs b/mock/server/src/main.rs
index 91dbf9c7..f53b9dd6 100644
--- a/mock/server/src/main.rs
+++ b/mock/server/src/main.rs
@@ -1,4 +1,3 @@
-extern crate actix;
extern crate actix_web;
extern crate bytes;
extern crate env_logger;
@rofrol
rofrol / rofrol.itermcolors
Created December 15, 2018 05:11
Ubuntu wsl colors
<--
Screen Text 0 0 0
Screen Background 255 255 255
Popup Text 255 255 255
Popup Background 0 0 0
255 255 255
0 0 178
0 166 0
@rofrol
rofrol / index.js
Last active June 6, 2018 10:53
Fixed to Absolute Important user script
// ==UserScript==
// @name Fixed to Absolute Important
// @namespace https://greasyfork.org/en/scripts/369282-fixed-to-absolute-important
// @description Stops elements from following you as you scroll down the page
// @version 1
// ==/UserScript==
// https://gist.github.com/rofrol/a52a36102daf59eeef91c715c0ae402b
// Based on https://alisdair.mcdiarmid.org/kill-sticky-headers/
@rofrol
rofrol / moje wnioski macbook vs.md
Created April 26, 2018 13:00
moje wnioski macbook vs
  • macbook ma najlepszy touchpad
  • oprogramowania mniej niż na Windows, a jeśli już to płatne. Ale to i tak lepiej niż Linux gdzie jest stary Skype, nie można udostępniać ekranu w Slacku, nie ma wielu programów. Czasami jest jakiś program na maca którego nie ma na Windows jak np. Sketch.
  • przełączanie między aplikacjami: Mi na przykład bardziej pasuje zmiana programu przez alt+tab niż przesuwanie trzema palcami lub pokazanie wszystkich okien. Dodatkowo to pokazanie nie zawsze pokazuje miniatury. Nie wiem od czego to zależy. Dodatkowo przełączanie cmd+tab na macu grupuje aplikacje zamiast pokazać wszystkie okna. Jest hyperswitch ale on nie zachowuje stałej kolejności choć może jest to w opcjach. Dodatkowo niektóre aplikacje nie pokazują się przy używaniu hyperswitch jak są w fullscreen, np. zoom.us.
  • zewnętrzny monitor: nie da się z domyślnym oprogramowaniem zrobić only extrnal. Zainstalowałem jeden otwartoźródłowy i polecany, to wyłączył mi dwa ekrany
  • na zewnętrznym monitorze znika mi czasami kursor - musz