Skip to content

Instantly share code, notes, and snippets.

View fasiha's full-sized avatar
💭
🧘‍♂️🐻

Ahmed Fasih fasiha

💭
🧘‍♂️🐻
View GitHub Profile
# Git branch in prompt
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}
# export PS1="\u@\h \W\[\033[32m\]\$(parse_git_branch)\[\033[00m\] $ "
export PS1="\u@\h \[\033[32m\]\w\[\033[33m\]\$(parse_git_branch)\[\033[00m\] $ "
alias ls='ls -G'
export CLICOLOR=1
export LSCOLORS=Gxfxcxdxbxegedabagacad
@SheldonWangRJT
SheldonWangRJT / Convert .mov or .MP4 to .gif.md
Last active April 27, 2024 19:01
Convert Movie(.mov) file to Gif(.gif) file in one command line in Mac Terminal

This notes is written by Sheldon. You can find me with #iOSBySheldon in Github, Youtube, Facebook, etc.

Need

Convert .mov/.MP4 to .gif

Reason

As a developer, I feel better to upload a short video when I create the pull request to show other viewers what I did in this PR. I tried .mov format directly got after finishing recording screen using Quicktime, however, gif offers preview in most web pages, and has smaller file size.

This is not limited to developer, anyone has this need can use this method to convert the files.

@pierrejoubert73
pierrejoubert73 / markdown-details-collapsible.md
Last active April 29, 2024 07:03
How to add a collapsible section in markdown.

How to add a collapsible section in markdown

1. Example

Click me

Heading

  1. Foo
  2. Bar
    • Baz
  • Qux
@joyrexus
joyrexus / README.md
Last active February 24, 2024 15:16
collapsible markdown

collapsible markdown?

CLICK ME

yes, even hidden code blocks!

print("hello world!")
@jasongilman
jasongilman / atom_clojure_setup.md
Last active January 11, 2024 09:13
This describes how I setup Atom for Clojure Development.

Atom Clojure Setup

This describes how I setup Atom for an ideal Clojure development workflow. This fixes indentation on newlines, handles parentheses, etc. The keybinding settings for enter (in keymap.cson) are important to get proper newlines with indentation at the right level. There are other helpers in init.coffee and keymap.cson that are useful for cutting, copying, pasting, deleting, and indenting Lisp expressions.

Install Atom

Download Atom

The Atom documentation is excellent. It's highly worth reading the flight manual.

(ns cljobs.resources.manage.os-projects
(:require [cljobs.resources.common :as c]
[cljobs.db.queries :as q]))
(def new-data (c/query-result q/user-os-projects))
(defn process-params
[ctx]
(-> (c/assoc-user ctx :os-project/user)
(update-in [:request :params]
@ohanhi
ohanhi / joy-of-composition.md
Last active February 3, 2021 18:14
The Joy of Composition - Why stateless rendering is pure bliss

This is a proposal for a lightning talk at the Reactive 2015 conference.

NOTE: If you like this, star ⭐ the Gist - the amount of stars decides whether it makes the cut!

The Joy of Composition

Why stateless rendering is pure bliss

React just got stateless components, meaning that they are in essence pure functions for rendering. Pure functions make it dead simple - even fun - to refactor your views

@masayu-a
masayu-a / gist:3e11168f9330e2d83a68
Created May 27, 2015 02:46
English translations of UniDic inflection forms, prepared by Irena Srdanovic, 18.1.2013 and 22.1.2013
Inflected forms (Ja) Inflected forms (En) Inflected forms (En)- description
ク語法 ku_wrd ku_wording
仮定形-一般 Cond.g conditional.general(katei)
仮定形-融合 Cond.int conditional.integrated(katei)
命令形 Imp imperative(meirei)
已然形-一般 Real.g realis.general(izen)
已然形-補助 Real.aux realis.auxiliary(izen)
意志推量形 Vol_tent volitional_tentative(ishi_suiryo)
未然形-サ Irr.sa irrealis.sa(mizen)
@masayu-a
masayu-a / gist:b3ce862336e47736e84f
Created May 27, 2015 02:43
English translations of UniDic inflection types, prepared by Irena Srdanovic, 18.1.2013 and 22.1.2013
Inflection type (Ja) Inflection type (En) Inflection type - description (En)
カ行変格 ka_irr kahen_verb.irregular
サ行変格 sa_irr sahen_verb.irregular
ザ行変格 za_irr zahen_verb.irregular
上一段-ア行 V1i.a kamiichidan_verb_i_row.a_column
上一段-カ行 V1i.ka kamiichidan_verb_i_row.ka_column
上一段-ガ行 V1i.ga kamiichidan_verb_i_row.ga_column
上一段-ザ行 V1i.za kamiichidan_verb_i_row.za_column
上一段-タ行 V1i.ta kamiichidan_verb_i_row.ta_column
@masayu-a
masayu-a / gist:e3eee0637c07d4019ec9
Last active February 1, 2024 16:47
English Tagset for UniDic - English translations of UniDic POS tags, prepared by Irena Srdanovic, 17.1.2013, checked by Ogiso, Den and Maekawa
PoS(Ja) PoS (En) PoS (En) - descriptions
代名詞 Pron pronoun
副詞 Adv adverb
助動詞 Aux auxiliary_verb
助詞-係助詞 P.bind particle(binding)
助詞-副助詞 P.adv particle(adverbial)
助詞-接続助詞 P.conj particle(conjunctive)
助詞-格助詞 P.case particle(case)
助詞-準体助詞 P.nom particle(nominal)