Skip to content

Instantly share code, notes, and snippets.

View itisrazza's full-sized avatar

Rareș Nistor (Razz) itisrazza

View GitHub Profile
@itisrazza
itisrazza / CenteredLookout.py
Last active April 29, 2021 10:50
SuperSize Script Dump
primary = get_screens()[0].Bounds
center = point(primary.X + primary.Width / 2, primary.Y + primary.Height / 2)
all_bounds = get_all_screen_bounds()
d_top = abs(center.Y - all_bounds.Top)
d_right = abs(center.X - all_bounds.Right)
d_bottom = abs(center.Y - all_bounds.Bottom)
d_left = abs(center.X - all_bounds.Left)
dw = min(d_left, d_right)
@itisrazza
itisrazza / Dotfiles.md
Last active November 2, 2020 22:23
Dotfiles Readme

Dotfiles installation

The dotfiles support bash (on Linux) and zsh (on macOS and Linux). These are meant to give me a consistent environment across the UNIX computers I use.

Before starting, make sure the repository isn't going to write over important existing files. It's a good idea to rename .bashrc and .zshrc to .bashrc.local and .zshrc.local.

# Create `.dotfiles` folder
mkdir ~/.dotfiles
cd ~/.dotfiles
@itisrazza
itisrazza / php-redirect.php
Created September 2, 2020 01:24
PHP Redirect Snippet
<?php
$somelink = "https://thegreatrazz.nz/";
header("HTTP/1.1 303 See Other");
header("Location: $somelink");
@itisrazza
itisrazza / keybase.md
Created May 20, 2019 01:03
Keybase Verification

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@itisrazza
itisrazza / timelapse.md
Last active August 23, 2017 08:24
A simple timelapse program written in Python and uses SimpleCV (for capturing photos) and ffmpeg (for making the video)

To use this you need to install SimpleCV and ffmpeg

For Ubuntu 16.04:

  • Download and run this script
  • Install ffmpeg using sudo apt install ffmpeg
  • Download and run timelapse.py

In terminal:

  • wget https://gist.github.com/thegreatrazz/bad1b2ccfcaaecc33d260febe933243e/raw/d3b1d09637532fd7fbd760d02d37562ec89e591a/install-python-simplecv.sh
  • sudo bash install-python-simplecv.sh
@itisrazza
itisrazza / install-python-simplecv.sh
Last active September 25, 2018 22:14
Install SimpleCV on Ubuntu 16.04
#!/bin/bash
#
# Installation script for SimpleCV
# on Ubuntu 16.04 and derivatives
#
# Created by Raresh Nistor
#
# NOTE: This is my first bash script,
# it's not going to have many safeguards