Skip to content

Instantly share code, notes, and snippets.

View divins's full-sized avatar

Marc Divins Castellvi divins

View GitHub Profile
#!/usr/bin/env bash
#
# post-clone-reset.sh — Debian 13+ post-clone sanity reset for Proxmox clones
#
# This script:
# - Regenerates SSH host keys
# - Resets machine-id (new on next boot)
# - Optionally sets a new hostname
# - Optionally configures a STATIC IP on the detected NIC (else leaves DHCP)
# - Clears logs, histories, and stale DHCP leases
@divins
divins / deadspace.html
Last active August 29, 2015 14:03
DeadSpace Inventory
<div id="effect-container">
<!-- n times -->
<div class="transform">
<a href="#"><i class="icon-map-marker"></i></a>
</div>
<!-- n times -->
</div>
@divins
divins / scrapper.rb
Created February 6, 2014 17:38
Coac scrapper
#Lets do it!
<input class="percent-selector" max="100" min="0" type="range" value="0">
<div class="cool-percent-icon">
<div class="moar-outter-shadow"></div>
<div class="outer-shadow"></div>
<canvas height="100" width="100"></canvas>
<div class="icon"><i class="icon-dropbox"></i></div>
</div>
<input class="percent-selector" max="100" min="0" type="range" value="0">
<div id="menu-container">
<button id="menu-button"><i class="icon-list"></i></button>
<nav id="menu">
<a href="#"><i class="icon-magnet"></i></a>
<a href="#"><i class="icon-user"></i></a>
<a href="#"><i class="icon-gamepad"></i></a>
<a href="#"><i class="icon-map-marker"></i></a>
<a href="#"><i class="icon-legal"></i></a>
<a href="#"><i class="icon-cogs"></i></a>
@divins
divins / dabblet.css
Created October 14, 2013 16:18 — forked from anonymous/dabblet.css
demo to explain chained transforms
/**
* demo to explain chained transforms
*/
* { margin: 0; }
.wrap, .wrap * { display: block; width: 4em; height: 4em; position: absolute; top: 25%; left: 50%}
.wrap { outline: dashed 1px dodgerblue; margin: 13em auto 0; }
.deg0 {
position: absolute;
animation: ani0 1s infinite;
<div class="input">
<input id="foo" placeholder="Foo">
<label for="foo">Foo</label>
</div>
<div class="input">
<input id="bar" placeholder="Bar">
<label for="bar">Bar</label>
</div>
@divins
divins / 0_reuse_code.js
Created October 13, 2013 10:24
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@divins
divins / http_digest_authentication.rb
Created January 22, 2013 14:36
Enable digest authentication at rspec controller tests
# This file goes to:
# spec/support/http_digest_authentication.rb
require 'digest/md5'
module HTTPDigestAuthentication
def authenticate_with_http_digest(user, password, realm)
ActionController::Base.class_eval { include ActionController::Testing }
unless @controller.methods.include?(:real_process_with_new_base_test)
@controller.instance_eval %q{
@divins
divins / README.md
Created July 4, 2012 13:42
Playing with Ember