This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[main] | |
plugins=ifupdown,keyfile | |
[ifupdown] | |
managed=false | |
# Fixes a WiFi issue in Debian 9 and Ubuntu >=17.04. | |
# If you're able to see a list of access points in NetworkManager, but unable to connect to any of them, you should try this. | |
# Source: https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/1681513/comments/1 | |
[device] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# | |
# Upload image(s) to imgur.com | |
# Copyright (C) 2014 Vivien Didelot <vivien@didelot.org> | |
# Licensed under GPL version 3, see http://www.gnu.org/licenses/gpl.txt | |
# | |
# Requires "jshon": | |
# http://kmkeen.com/jshon/ | |
# | |
# Alternatives, which suck: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
// Add this as an "Other HTML" widget to your wiki's navigation menu. | |
window.onload = setTimeout(function(){ | |
while (wikispaces_page.indexOf(" ") != -1){ | |
wikispaces_page = wikispaces_page.replace(" ", "+"); | |
} | |
var anchors = document.getElementsByTagName("a"); | |
for (var i = 0; i < anchors.length; i++) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
volatile int rate[10]; // array to hold last ten IBI values | |
volatile unsigned long sampleCounter = 0; // used to determine pulse timing | |
volatile unsigned long lastBeatTime = 0; // used to find IBI | |
volatile int P =512; // used to find peak in pulse wave, seeded | |
volatile int T = 512; // used to find trough in pulse wave, seeded | |
volatile int thresh = 525; // used to find instant moment of heart beat, seeded | |
volatile int amp = 100; // used to hold amplitude of pulse waveform, seeded |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Instaload | |
// @namespace https://fysac.me | |
// @description Autoloads the next page of photos on Instagram as you scroll down. | |
// @include http://instagram.com/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Fixed - I am an idiot! | |
The JSON selector "serverID" (line 12) should be "serverId". | |
Then remove "shouldRead" from the whole equation. | |
Bugged code preserved below for posterity. | |
*/ | |
@SuppressWarnings("unchecked") | |
public void sendSessionRequest(String serverIdHash) throws IOException { | |
JSONObject payload = new JSONObject(); | |
payload.put("accessToken", accessToken); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$timeout = 300; // 5 minutes | |
$time = time(); | |
$ip = $_SERVER["REMOTE_ADDR"]; | |
$file = "users.txt"; | |
$arr = file($file); | |
$users = 0; | |
for ($i = 0; $i < count($arr); $i++){ | |
if ($time - intval(substr($arr[$i], strpos($arr[$i], " ") + 4)) > $timeout){ |