I hereby claim:
- I am riteshshrv on github.
- I am riteshshrv (https://keybase.io/riteshshrv) on keybase.
- I have a public key ASDWkpzpQntCgL2DtmZRmberbNh4im_yCeCLwm5upM75hQo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
# I needed to print out ascii tables from data in the form: | |
# [ ('column 0 title', 'column 1 title' ..), | |
# ('row 0, column 0 data', 'row 0, column 1 data' ...) ...] | |
# | |
# and surprisingly it got complicated because of variable lengths of the data. | |
# I googled for 'standard' ways of doing this and I found suggestions like: | |
# http://stackoverflow.com/questions/5909873/python-pretty-printing-ascii-tables | |
# ...which were a bit dated and hard to read or full scale modules like: | |
# | |
# http://pypi.python.org/pypi/texttable/ |
Byobu Commands | |
============== | |
byobu Screen manager | |
Level 0 Commands (Quick Start) | |
------------------------------ | |
<F2> Create a new window |
Free O'Reilly books and convenient script to just download them.
Thanks /u/FallenAege/ and /u/ShPavel/ from this Reddit post
How to use:
download.sh
file and put it into a directory where you want the files to be saved.cd
into the directory and make sure that it has executable permissions (chmod +x download.sh
should do it)./download.sh
and wee there it goes. Also if you do not want all the files, just simply comment the ones you do not want.package csvdata | |
// csvdata complements the csv package by allowing you to map a custom structure to | |
// the columns of data in a CSV file. The struct needs to be annotated so that each | |
// field can match a column in the data | |
// | |
// type Person struct { | |
// FirstName string `field:"First Name"` | |
// Second_Name string | |
// Age int | |
// } |
* |
Xft.dpi: 96 | |
Xft.antialias: true | |
Xft.hinting: true | |
Xft.rgba: rgb | |
Xft.autohint: false | |
Xft.hintstyle: hintslight | |
Xft.lcdfilter: lcddefault | |
XTerm*background: #222D31 | |
XTerm*foreground: #d8d8d8 |
-- Create a group | |
CREATE ROLE readaccess; | |
-- Grant access to existing tables | |
GRANT USAGE ON SCHEMA public TO readaccess; | |
GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess; | |
-- Grant access to future tables | |
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess; |
#!/usr/bin/env bash | |
numDisplays=$(xrandr --current | grep '\bconnected' | wc -l) | |
outputs="--output eDP1 --primary --mode 2880x1620 --pos 2880x0 --dpi 96 --scale 1x1" | |
xrandr --output HDMI1 --off | |
xrandr --output DP2 --off | |
if xrandr | grep "HDMI1 connected"; then | |
outputs+=" --output HDMI1 --auto --mode 1920x1080 --pos 0x0 --right-of eDP1 --scale 1.5x1.5" |