Skip to content

Instantly share code, notes, and snippets.

🌺
Looking for it

Kuanysh Bayandinov kuka

View GitHub Profile
@kuka
kuka / normalizeCase.ts
Created Feb 22, 2019
Typescript: normalizes string case
View normalizeCase.ts
export const normalizeCase = (str: string) =>
str
.replace(/\b(?:[a-zA-Z]\.){2,}/, a => a.toUpperCase())
.replace(/(?!\b(?:[a-zA-Z]\.){2,})/, a => a.toLowerCase())
.replace(/(\w*[a-z0-9_]+\w*)/g, a => a.toLowerCase())
@kuka
kuka / autocadcolors.js
Last active May 26, 2018
AutoCAD colors index with HEX and RGB equivalents. https://github.com/kuka/autocad-colors-index
View autocadcolors.js
// AutoCAD 0-255 colors mapped with equivalents in HEX and RGB
// source: http://sub-atomic.com/~moses/acadcolors.html
export default [{
"aci": 0,
"hex": "#000000",
"rgb": "rgb(0,0,0)"
}, {
"aci": 1,
"hex": "#FF0000",
View vim-on-heroku.sh
#!/usr/bin/env bash
curl https://s3.amazonaws.com/heroku-jvm-buildpack-vi/vim-7.3.tar.gz --output vim.tar.gz
mkdir vim && tar xzvf vim.tar.gz -C vim
export PATH=$PATH:/app/vim/bin
View gist:9bdd2af6e637fe085a82
git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --"
View gist:e9973c53e6323dbeef7b
git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
– git lg
– git lg -p – with changes
View gist:c29948836365a6c1c01e
### Keybase proof
I hereby claim:
* I am kuka on github.
* I am kuka (https://keybase.io/kuka) on keybase.
* I have a public key whose fingerprint is 019A 711D 20DD 3221 5816 EBD0 6B1A 7D45 8FC9 086E
To claim this, I am signing this object:
You can’t perform that action at this time.