Skip to content

Instantly share code, notes, and snippets.

Avatar

BLVK.ART blvkoblsk

View GitHub Profile
@blvkoblsk
blvkoblsk / bbs.js
Created Jun 20, 2018 — forked from TooTallNate/bbs.js
Running a node.js REPL over `curl`
View bbs.js
/**
* Requires node v0.7.7 or greater.
*
* To connect: $ curl -sSNT. localhost:8000
*/
var http = require('http')
, repl = require('repl')
, buf0 = new Buffer([0])
View keybase.md

Keybase proof

I hereby claim:

  • I am blvkoblsk on github.
  • I am blvkoblsk (https://keybase.io/blvkoblsk) on keybase.
  • I have a public key ASDxBCblbfRmtVaQQQ27kZ3dIi3metRyRzi6b593a2EYbQo

To claim this, I am signing this object:

@blvkoblsk
blvkoblsk / ansi-colors.py
Created Aug 18, 2017
ANSI COLORS - PYTHON BASH SCRIPT + MODULE
View ansi-colors.py
#!/usr/bin/env python
# -*- encoding: utf-8 -*-
""" An efficient and simple ANSI colours module (and also a powerfull script), with functions to print text using colours.
About the convention for the names of the colours :
* for the eight colours black, red, green, yellow, blue, magenta, cyan, white:
* the name in minuscule is for colour **with bold** (example 'yellow'),
* the name starting with 'B' is for colour **without bold** (example 'Byellow'),
* the name starting with a capital letter is for the background colour (example 'Yellow').* for the special effects (blink, italic, bold, underline, negative), **not always supported** :
View blinking_bash.bash
#!/bin/bash
clear
echo
echo -e " ---------------------------- "
echo
echo -e " \033[0;97;2:31;5mWHITE FG TEXT BLINKING\033[0m";
echo
echo -e " \033[39;31;2:39;5mRED FG TEXT BLINKING\033[0m";
echo
@blvkoblsk
blvkoblsk / tput_colors.bash
Created Aug 18, 2017
TPUT COLORS - BASH SHELL SCRIPT
View tput_colors.bash
#!/bin/bash
# TPUT COLORS - BASH SHELL SCRIPT
echo
echo -e "$(tput bold) reg bld und tput-command-colors$(tput sgr0)";
for i in $(seq 1 8); do
echo " $(tput setaf $i)Text$(tput sgr0) $(tput bold)$(tput setaf $i)Text$(tput sgr0) $(tput sgr 0 1)$(tput setaf $i)Text$(tput sgr0) \$(tput setaf $i)"
done
echo ' Bold $(tput bold)'
@blvkoblsk
blvkoblsk / bash_colors_ansi_esc.bash
Created Aug 18, 2017
BASH COLORS - ANSI ESCAPE
View bash_colors_ansi_esc.bash
#!/bin/bash
# BASH COLORS - ANSI ESCAPE
# NORMAL
txtblk='\e[0;30m' # Black
txtred='\e[0;31m' # Red
txtgrn='\e[0;32m' # Green
txtylw='\e[0;33m' # Yellow
txtblu='\e[0;34m' # Blue
@blvkoblsk
blvkoblsk / bash_prompt_date.bash
Last active Aug 18, 2017
BASH PROMPT - HOST :: DATE :: TIME :: CWD :: $
View bash_prompt_date.bash
#!/bin/bash
#### BASH PROMPT - HOST :: DATE :: TIME :: CWD :: $
PS1="\[\e[34m\]\h\[\e[m\] :: \[\e[32m\]\d\[\e[m\] :: \[\e[32m\]\A\[\e[m\] :: \[\e[36;40m\]\w\[\e[m\] :: \[\e[31m\]\\$\[\e[m\] "
@blvkoblsk
blvkoblsk / bash_prompt.bash
Last active Aug 18, 2017
BASH PROMPT - GIT STATUS & ANSI COLOR
View bash_prompt.bash
#!/bin/bash
#### BASH_PROMPT W/ GIT STATUS & ANSI COLOR
#### Created for VPS instance - 08.17.2017
# get current branch in git repo
function parse_git_branch() {
BRANCH=`git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/'`
if [ ! "${BRANCH}" == "" ]
then
@blvkoblsk
blvkoblsk / blvkGradientBG.css
Created Aug 18, 2017 — forked from anonymous/my.css
Black & Blue Gradient CSS Variation
View blvkGradientBG.css
background: linear-gradient(320deg, #000000, #000000, #5785b8, #374a5f, #0e2b4d, #5785b8, #000000);
background-size: 1400% 1400%;
-webkit-animation: blvkGradientBG 45s ease infinite;
-moz-animation: blvkGradientBG 45s ease infinite;
-o-animation: blvkGradientBG 45s ease infinite;
animation: blvkGradientBG 45s ease infinite;
@-webkit-keyframes blvkGradientBG {
    0%{background-position:11% 0%}
    50%{background-position:90% 100%}
    100%{background-position:11% 0%}
@blvkoblsk
blvkoblsk / byobuCommands
Created Aug 16, 2017 — forked from jshaw/byobuCommands
Byobu Commands
View byobuCommands
Byobu Commands
==============
byobu Screen manager
Level 0 Commands (Quick Start)
------------------------------
<F2> Create a new window