Skip to content

Instantly share code, notes, and snippets.

function refreshPage() {
$.ajax({
url: document.location.href,
success: function () {
refreshPage();
}
});
}
refreshPage();
@marcelovsantos
marcelovsantos / pinned-color-tab.css
Last active July 20, 2016 14:47
pinned-color-tab.css
/**
* Install https://addons.mozilla.org/en-US/firefox/addon/stylish/
*/
@namespace url(http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul);
.tabbrowser-tab[pinned="true"]:nth-child(2):not([selected]) .tab-content{
background: #F2CB1D !important;
}
.tabbrowser-tab[pinned="true"]:nth-child(3):not([selected]) .tab-content{
@marcelovsantos
marcelovsantos / export-git-diff.sh
Last active May 5, 2016 14:52
export-git-diff.sh
git diff master branch --name-only | cpio -dpv folder
@marcelovsantos
marcelovsantos / click-all-links.js
Last active February 22, 2016 22:48
Click in all anchors page
@marcelovsantos
marcelovsantos / increment_year_semester.php
Last active December 16, 2015 12:17
Increment year and semester mathematically
<?php
/**
* Increment year and semester mathematically
*
* @param int $year
* @param int $semester
* @param int $increment
* @return string
*/
function increment_year_semester($year, $semester, $increment = 1)
@marcelovsantos
marcelovsantos / chage-mac.sh
Last active May 20, 2018 09:03
Change MAC Address Ubuntu 14.04
sudo nmcli nm wifi off
echo wifi off
sleep 5
sudo ip link set wlan0 address 00:0d:c2:10:1a:00
echo changed mac
sleep 5
sudo nmcli nm wifi on
echo wifi on