Skip to content

Instantly share code, notes, and snippets.

View dr563105's full-sized avatar

Deepak Ramani dr563105

View GitHub Profile
@ziritrion
ziritrion / pythondata.md
Last active July 24, 2024 06:38
Python and libraries cheat sheet

Python

Lists

  • [1, 2, 3, 4, 5]

Power operator (2^5)

  • 2 ** 5

Square root (power operator trick)

  • 9 ** 0.5
@vext01
vext01 / vimura.md
Last active February 14, 2024 03:36
Vim+Zathura+Synctex

Vim+Zathura+Synctex

  • In a script called 'vimura':
#!/bin/sh
echo $1
zathura -s -x "gvim --servername $1 -c \"let g:syncpdf='$1'\" --remote +%{line} %{input}" $*
@Kartones
Kartones / postgres-cheatsheet.md
Last active July 23, 2024 09:14
PostgreSQL command line cheatsheet

PSQL

Magic words:

psql -U postgres

Some interesting flags (to see all, use -h or --help depending on your psql version):

  • -E: will describe the underlaying queries of the \ commands (cool for learning!)
  • -l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)