Skip to content

Instantly share code, notes, and snippets.

View mike-lawrence's full-sized avatar

Mike Lawrence mike-lawrence

  • Halifax, Nova Scotia, Canada
View GitHub Profile
@FullStackAlex
FullStackAlex / ANSI.md
Last active September 25, 2020 18:09 — forked from fnky/ANSI.md
ANSI Escape Codes

Escape code / character

An Escape code is a command for a string interpretting programm to treat following characters as a command (but not as simple text, as by default).

There are different notations for an ASCII escape code:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1b
  • Decimal: 27
@fnky
fnky / ANSI.md
Last active May 9, 2024 15:36
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
# Custom history configuration
# Run script using:
# chmod u+x better_history.sh
# sudo su
# ./better_history.sh
echo ">>> Starting"
echo ">>> Loading configuration into /etc/bash.bashrc"
echo "HISTTIMEFORMAT='%F %T '" >> /etc/bash.bashrc
echo 'HISTFILESIZE=-1' >> /etc/bash.bashrc
@johnatasjmo
johnatasjmo / source_files_from_folder.R
Created January 20, 2018 16:44
R - Source all files within folder
setwd("~/rProgramming")
files.sources = list.files()
sapply(files.sources, source)
@whizzzkid
whizzzkid / XPS-15 9560 Getting Nvidia To Work on KDE Neon
Last active December 3, 2022 15:43
[XPS 15 Early 2017 9560 kabylake] Making Nvidia Drivers + (CUDA 8 / CUDA 9 / CUDA 9.1) + Bumblebee work together on linux ( Ubuntu / KDE Neon / Linux Mint / debian )
# Instructions for 4.14 and cuda 9.1
# If upgrading from 4.13 and cuda 9.0
$ sudo apt-get purge --auto-remove libcud*
$ sudo apt-get purge --auto-remove cuda*
$ sudo apt-get purge --auto-remove nvidia*
# also remove the container directory direcotory at /usr/local/cuda-9.0/
# Important libs required with 4.14.x with Cuda 9.X
$ sudo apt install libelf1 libelf-dev
@aronatkins
aronatkins / install-rstudio-daily.sh
Last active February 10, 2022 08:54
Install RStudio daily build on OSX/macOS or Ubuntu Linux
#!/bin/bash
#
# Installs the latest RStudio daily desktop build for OSX/macOS and Ubuntu(amd64)
#
# https://support.rstudio.com/hc/en-us/articles/203842428-Getting-the-newest-RStudio-builds
set -e
install_macos_daily() {
REDIRECT_URL="https://www.rstudio.org/download/latest/daily/desktop/mac/RStudio-latest.dmg"
@jsundram
jsundram / README.md
Last active June 16, 2016 14:40
Install AggDraw for OSX 10.7+.