Skip to content

Instantly share code, notes, and snippets.


Block or report user

Report or block sogaiu

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
sogaiu /
Last active Jan 15, 2020
vim-iced with socket repl
  1. Using Ubuntu derivative

  2. Install neovim from source (see neovim wiki)

  3. Install vim-plug

    curl -fLo ~/.local/share/nvim/site/autoload/plug.vim --create-dirs \
sogaiu /
Last active Jan 15, 2020
dealing with NODE_MODULE_VERSION mismatch for vscode extension

Tried to use the node-ctags module in a VSCode (1.41.1) extension and got:

Activating extension 'undefined_publisher.aclomplete' failed: The module '/home/user/src/aclomplete/node_modules/ctags/build/Release/ctags.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 72. This version of Node.js requires
NODE_MODULE_VERSION 73. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`)..

Addressed by:

sogaiu / gist:2e690bf2020e669601609b3c7e8e7f08
Created Jan 11, 2020
use virtualenv with gigasquid's "hugging fact gpt with clojure" tutorial
View gist:2e690bf2020e669601609b3c7e8e7f08
# some tweaks to instructions at:
mkdir hugging-face-gpt-clojure
cd hugging-face-gpt-clojure
# keep system clean by using virtualenv
sudo apt install virtualenv
virtualenv -p python3 hfgc
source hfgc/bin/activate
sogaiu / cm.clj
Created Dec 31, 2019
clojure.main/repl using system classloader
View cm.clj
;; modified clojure.main
;; Copyright (c) Rich Hickey All rights reserved. The use and
;; distribution terms for this software are covered by the Eclipse Public
;; License 1.0 ( which can be found
;; in the file epl-v10.html at the root of this distribution. By using this
;; software in any fashion, you are agreeing to be bound by the terms of
;; this license. You must not remove this notice, or any other, from this
;; software.
sogaiu /
Created Dec 25, 2019
swap the fn2 button with the right mouse button for a elecom deft pro mouse
#! /bin/sh
# from:
# use the following to see the existing arrangement
#xmodmap -pp
# swap the Fn2 button with the right mouse button
xmodmap -e "pointer = 1 2 11 4 5 6 7 8 9 10 3 12"
sogaiu /
Created Dec 25, 2019
configure lcd and external for onyx boox max 2
#! /bin/sh
# adapted:
xrandr --output eDP1 --auto --primary
xrandr --output HDMI1 --auto
xrandr --output HDMI1 --auto --same-as eDP1
# adapted:
xrandr --output HDMI1 --panning 2104x1560
sogaiu / java-annotations-via-interop.clj
Created Dec 25, 2019
how to do java annotations in clojure via interop
View java-annotations-via-interop.clj
;; thanks to lvh --
(definterface LibC
(^int gettimeofday
[^Timeval ^{Out {} Transient {}} tv
^Pointer unused]))
fn main() {
println!("Hello World!");
View hello.c
#include <stdlib.h>
int main() {
return 0;
You can’t perform that action at this time.