Skip to content

Instantly share code, notes, and snippets.

$ # following https://wiki.archlinux.org/index.php/Nix
$ # hello works
$ nix-env -iA nixpkgs.fmit
...
building '/nix/store/l8dcfc0baypl07dmdvgl38wkxcccr7bh-user-environment.drv'...
created 15 symlinks in user environment
$ fmit
bash: fmit: command not found
$ echo $PATH
/home/sergeykish/.nix-profile/bin:/opt/google-cloud-sdk/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/opt/plan9/bin
@sergeykish
sergeykish / xmonad.hs
Created August 27, 2020 19:57
wmii like xmonad, no decorations
import XMonad
import XMonad.Hooks.EwmhDesktops
import XMonad.Hooks.DynamicLog
import XMonad.Hooks.ManageDocks
import XMonad.Hooks.ManageHelpers
import XMonad.Layout.Groups.Wmii
import XMonad.Util.Run
import XMonad.Util.EZConfig
import System.IO
import XMonad.Layout.NoBorders
@sergeykish
sergeykish / break-calliope-exceptions
Last active June 15, 2020 16:05
gsutil rsync # same name for file and folder
$ gsutil rsync -r gs://sergeykish.com .
> /opt/google-cloud-sdk/bin/bootstrapping/gsutil.py(6)<module>()
-> """A convenience wrapper for starting gsutil."""
(Pdb) b /opt/google-cloud-sdk/lib/googlecloudsdk/calliope/exceptions.py:527
Breakpoint 1 at /opt/google-cloud-sdk/lib/googlecloudsdk/calliope/exceptions.py:527
(Pdb) c
WARNING: gsutil rsync uses hashes when modification time is not available at
both the source and destination. Your crcmod installation isn't using the
module's C extension, so checksumming will run very slowly. If this is your
@sergeykish
sergeykish / xmonad.hs
Created June 6, 2020 13:28
XMonad.Layout.Groups.Wmii
import XMonad
import XMonad.Hooks.EwmhDesktops
import XMonad.Hooks.DynamicLog
import XMonad.Hooks.ManageDocks
import XMonad.Hooks.ManageHelpers
import XMonad.Layout.Groups.Wmii
import XMonad.Util.Run
import XMonad.Util.EZConfig
import System.IO
import Data.Default
@sergeykish
sergeykish / makepkg
Created June 2, 2020 17:43
Build netsurf TARGET=framebuffer on Arch Linux
COMPILE: utils/utils.c
MSGSPLIT: Language: de Filter: fb
MSGSPLIT: Language: en Filter: fb
MSGSPLIT: Language: fr Filter: fb
MSGSPLIT: Language: it Filter: fb
MSGSPLIT: Language: nl Filter: fb
LINK: nsfb
/usr/bin/ld: build/Linux-framebuffer/frontends_framebuffer_font_internal.o:/home/sergeykish/abs/netsurf-fb/src/netsurf-3.9/build/Linux-framebuffer/font-ns-sans.h:30: multiple definition of `fb_italic_section_table'; build/Linux-framebuffer/build_Linux-framebuffer_font-ns-sans.o:/home/sergeykish/abs/netsurf-fb/src/netsurf-3.9/build/Linux-framebuffer/font-ns-sans.c:1384: first defined here
/usr/bin/ld: build/Linux-framebuffer/frontends_framebuffer_font_internal.o:/home/sergeykish/abs/netsurf-fb/src/netsurf-3.9/build/Linux-framebuffer/font-ns-sans.h:31: multiple definition of `fb_italic_sections'; build/Linux-framebuffer/build_Linux-framebuffer_font-ns-sans.o:/home/sergeykish/abs/netsurf-fb/src/netsurf-3.9/build/Linux-framebuffer/font-ns-sans.c:2156: first defined here
/usr/bin/ld: build/Linux-framebuffer/f
@sergeykish
sergeykish / README
Last active June 1, 2020 17:46
xserver without misc font
[xorg-server]
XMonad default theme font
Reported as present
$ # font was not present, not defined as xorg-server dependency
[ 64816.350] (WW) The directory "/usr/share/fonts/misc" does not exist.
[ 64816.350] Entry deleted from font path.
[ 64816.350] (WW) The directory "/usr/share/fonts/OTF" does not exist.
@sergeykish
sergeykish / list conditions
Created May 25, 2020 15:33
Group media rules
[...document.styleSheets].flatMap(s =>
[...s.cssRules]
.filter(r => r.type === CSSRule.MEDIA_RULE)
.map(r => r.conditionText)
.filter((v,i,a) => a.indexOf(v) === i)
).join("\n")
"(max-width: 640px)
(prefers-color-scheme: dark)
(max-width: 980px)
(max-width: 816px)
@sergeykish
sergeykish / makepkg
Last active June 2, 2020 17:46
makepkg wmii on Arch Linux
==> Making package: wmii 3.9.2-4 (Sun 24 May 2020 09:42:31 AM EEST)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
-> Found wmii+ixp-3.9.2.tbz
-> Found fix-freetype-include.patch
==> Validating source files with md5sums...
wmii+ixp-3.9.2.tbz ... Passed
fix-freetype-include.patch ... Passed
==> Extracting sources...
@sergeykish
sergeykish / mach-build
Last active May 9, 2020 11:51
fatal error: 'nsISupports.h' file not found
0:02.63 Clobber not needed.
0:02.63 Adding make options from c:\mozilla-source\mozilla-central\mozconfig
MOZ_OBJDIR=c:/mozilla-source/mozilla-central/obj-x86_64-pc-mingw32
OBJDIR=c:/mozilla-source/mozilla-central/obj-x86_64-pc-mingw32
FOUND_MOZCONFIG=c:/mozilla-source/mozilla-central/mozconfig
export FOUND_MOZCONFIG
0:02.71 c:\mozilla-build\bin\mozmake.EXE -f client.mk -s
0:04.00 Elapsed: 0.00s; From dist/public: Kept 0 existing; Added/updated 0; Removed 0 files and 0 directories.
0:04.04 Elapsed: 0.08s; From dist/xpi-stage: Kept 88 existing; Added/updated 0; Removed 0 files and 0 directories.
0:04.05 Elapsed: 0.00s; From dist/private: Kept 0 existing; Added/updated 0; Removed 0 files and 0 directories.
JavaScript error: resource://gre/modules/TelemetryController.jsm, line 710: Error: string + boolean is not allowed
JavaScript error: chrome://global/content/elements/tabbox.js, line 465: Error: string + number is not allowed
JavaScript error: resource://gre/modules/TelemetryEnvironment.jsm, line 1350: Error: string + null is not allowed
JavaScript error: resource:///modules/sessionstore/SessionStore.jsm, line 1609: Error: string + number is not allowed
JavaScript error: resource://gre/modules/CaptiveDetect.jsm, line 263: Error: string + number is not allowed
JavaScript error: resource://gre/modules/SearchService.jsm, line 2332: Error: string + boolean is not allowed
Extension error: can't access property "linkedBrowser", tab is undefined resource://gre/modules/ExtensionActions.jsm:312 :: isShownForTab@resource://gre/modules/ExtensionActions.jsm:312:17
onManifestEntry@chrome://browser/content/parent/ext-pageAction.js:135:27
async*asyncEmitManifestEntry@resource://gre/modules/ExtensionCommon.jsm:1546:18
async*r