Skip to content

Instantly share code, notes, and snippets.

Avatar

Raziman Mahathir issadarkthing

  • Malaysia
View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am issadarkthing on github.
  • I am raziman (https://keybase.io/raziman) on keybase.
  • I have a public key ASCT40Kkeh9tTY5tEl3nU5m-UrSaHjnPeSLQSUCl476WWgo

To claim this, I am signing this object:

View userChrome.css
@-moz-document url-prefix("https://fosstodon.org") {
.compose-panel .autosuggest-textarea__textarea {
background: #282c37;
}
.compose-form__sensitive-button {
background: #282c37 !important;
}
.icon-button:active, .icon-button:focus, .icon-button:hover {
@issadarkthing
issadarkthing / init.vim
Last active Dec 17, 2020
toggle neovim terminal window
View init.vim
let s:term_window = -1
let s:term_buffer = -1
let s:term_job_id = -1
function! TerminalOpen()
" Check if buffer exists, if not create a window and a buffer
if !bufexists(s:term_buffer)
" Creates a window call monkey_terminal
new local_terminal
@issadarkthing
issadarkthing / wait-all.clj
Last active Oct 1, 2020
Clojure function that evaluates long running functions and wait for all functions return.
View wait-all.clj
(ns script
(:require [clojure.core.async :as async]))
(defn long-computation
"simulate long running operation"
[x]
(Thread/sleep 1000)
(rand-int x))
View get_progress_string.sh
#!/bin/bash
# getProgressString <TOTAL ITEMS> <FILLED LOOK> <NOT FILLED LOOK> <STATUS> <DELIMETER>
# For instance:
# $ getProgressString 10 "#" "-" 50 "|"
# #####|-----
ITEMS="$1" # The total number of items(the width of the bar)
FILLED_ITEM="$2" # The look of a filled item
NOT_FILLED_ITEM="$3" # The look of a not filled item
STATUS="$4" # The current progress status in percent