Skip to content

Instantly share code, notes, and snippets.

View RidaAyed's full-sized avatar

Rida Ayed RidaAyed

View GitHub Profile
@RidaAyed
RidaAyed / test_icsv2ledger.sh
Last active June 25, 2018 13:55
$ git clone https://gist.github.com/RidaAyed/465a90d881b2fd676e1daffe715f9f77 && cd 465a90d881b2fd676e1daffe715f9f77/ && bash test_icsv2ledger.sh
#!/usr/bin/env bash
#######################################################################
# Testing icsv2ledger #
#######################################################################
#######################################################################
# Echo console messages a bit more flashy #
#######################################################################
flashy_echo() {
msg="# $* #"

Change resolution in tty console

I wanted my external screen to work in it's correct resolution while being on the console (without Xorg).

Here's what I've done to get it work:

  1. On boot select Hardware info and look for your desired resolution code e.g. 895
  2. Edit /boot/syslinux/syslinux.cfg
  3. Add vga=895 to the APPEND line in your appropriate block
#!/bin/bash
##########################################
## SCRIPT VERSION 1.0.5 ##
## AUTHOR: MARKUS (www.och-group.de) ##
## Requires apt-get install: ##
## libtiff-tools ##
## tesseract\* ##
## libtiff-dev ##
## pdftk ##
## imagemagick ##
#!/usr/bin/env bash
# No more restore session messages
#######################################################################
# Chrome Shut-Up #
#######################################################################
sed -i 's/"exited_cleanly":false/"exited_cleanly":true/' ~/.config/chromium/'Local State'
sed -i 's/"exited_cleanly":false/"exited_cleanly":true/; s/"exit_type":"[^"]\+"/"exit_type":"Normal"/' ~/.config/chromium/Default/Preferences
chromium --no-default-browser-check --no-first-run --disable-infobars --disable-session-crashed-bubble
@RidaAyed
RidaAyed / .vimrc
Last active January 1, 2018 15:51
Append this line to your .vimrc
"Format JSON in vim. Needs python enabled vim version
nmap =j :%!python -m json.tool<CR>