Skip to content

Instantly share code, notes, and snippets.

View ph4un00b's full-sized avatar
:shipit:
0.5 * (1 + srqt(5))

carbon based lifeform ph4un00b

:shipit:
0.5 * (1 + srqt(5))
  • l33t l4mer
  • Latam
  • 18:24 (UTC -06:00)
View GitHub Profile
# Unix (Terminal)
open -a "Google Chrome" --args --disable-gpu-vsync --disable-frame-rate-limit
# Windows (Command prompt)
start chrome --args --disable-gpu-vsync --disable-frame-rate-limit
@JoeyBurzynski
JoeyBurzynski / 55-bytes-of-css.md
Last active May 15, 2024 20:11
58 bytes of css to look great nearly everywhere

58 bytes of CSS to look great nearly everywhere

When making this website, i wanted a simple, reasonable way to make it look good on most displays. Not counting any minimization techniques, the following 58 bytes worked well for me:

main {
  max-width: 38rem;
  padding: 2rem;
  margin: auto;
}
@fay59
fay59 / Quirks of C.md
Last active January 23, 2024 04:24
Quirks of C

Here's a list of mildly interesting things about the C language that I learned mostly by consuming Clang's ASTs. Although surprises are getting sparser, I might continue to update this document over time.

There are many more mildly interesting features of C++, but the language is literally known for being weird, whereas C is usually considered smaller and simpler, so this is (almost) only about C.

1. Combined type and variable/field declaration, inside a struct scope [https://godbolt.org/g/Rh94Go]

struct foo {
   struct bar {
 int x;
@patriciogonzalezvivo
patriciogonzalezvivo / GLSL-Noise.md
Last active May 24, 2024 03:20
GLSL Noise Algorithms

Please consider using http://lygia.xyz instead of copy/pasting this functions. It expand suport for voronoi, voronoise, fbm, noise, worley, noise, derivatives and much more, through simple file dependencies. Take a look to https://github.com/patriciogonzalezvivo/lygia/tree/main/generative

Generic 1,2,3 Noise

float rand(float n){return fract(sin(n) * 43758.5453123);}

float noise(float p){
	float fl = floor(p);
  float fc = fract(p);
@msurguy
msurguy / list.md
Last active January 26, 2018 15:16
List of CMSs built with Laravel (stable and in dev)
@rtablada
rtablada / example.html
Created March 22, 2014 23:38
Allow awesome uploaders in Gumby
<div class="append field fancy-uploader">
<input type="text" class="input xwide" placeholder="File">
<input type="file" name="picture">
<div class="primary btn medium">
<button>Upload</button>
</div>
</div>

Mac OS Python Installation for Scientific Computing

This gist describes how to install the basic tools you'll need to do scientific computing with Python on Mac OS X. These have been tested with Mac OS X 10.6 and 10.7.

Your Mac comes with Python installed by in /usr/bin/; however, you probably don't want to use that Python because it is rarely updated and, it's not a good idea to mess with that which OS X has installed.

@JeffreyWay
JeffreyWay / tip.sh
Created August 15, 2013 17:51
Ever want to undo everything that you've worked on since the last commit (including adding new files)? Here's a little alias to help with that.
alias gundo='git reset HEAD~ && git clean -df'
@JeffreyWay
JeffreyWay / gist:6176883
Created August 7, 2013 18:19
Add this to your bash_profile. Now, whenever you need to fetch your ssh-key, just type sshkey, and it'll be copied to your clipboard.
alias sshkey="cat ~/.ssh/id_rsa.pub | pbcopy && echo 'Copied to clipboard.'"
@JeffreyWay
JeffreyWay / migration.php
Last active April 28, 2016 06:19
What else would you want on a typical pivot table...say for posts and tags.
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
class PivotPostTagTable extends Migration {
/**
* Run the migrations.
*