Install osxfuse
(3.x.x) from https://github.com/osxfuse/osxfuse/releases.
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew update
osxfuse
(3.x.x) from https://github.com/osxfuse/osxfuse/releases.ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew update
#include <stdio.h> | |
#include <math.h> | |
int main() { | |
double s=0; | |
for(int i=1; i<=10000; i++) { | |
s=s+(1/pow(i, 2)); | |
printf("%d %lf %lf %lf\n", i, s, pow(i,2), 1/pow(i,2) ); | |
} |
$ brew install autoconf automake bison27 gd freetype t1lib mariadb gettext zlib mcrypt
curl -L https://github.com/php/php-src/pull/685.diff | patch -p1
[2015-08-04 00:01:41] alex@vostok:/tmp/test$ carthage bootstrap | |
*** No Cartfile.resolved found, updating dependencies | |
*** Fetching SwiftShell | |
*** Checking out SwiftShell at "4aeb5d7daa4c87d07e937c0238d8476dfcb809be" | |
*** xcodebuild output can be found in /var/folders/lv/tlgk81yd4kn23dkfv9qpdcr40000gn/T/carthage-xcodebuild.DpHcij.log | |
*** Building scheme "SwiftShell" in SwiftShell.xcodeproj | |
2015-08-04 00:01:57.120 xcodebuild[12527:9376026] DVTAssertions: Warning in /SourceCache/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-7546/Xcode3Core/LegacyProjects/Frameworks/DevToolsCore/DevToolsCore/SpecificationTypes/BuiltInSpecifications/Compilers/XCGccMakefileDependencies.m:77 | |
Details: Failed to load dependencies output contents from ``/Users/alex/Library/Developer/Xcode/DerivedData/SwiftShell-awlfnhhukkknlcatgirterfmqujr/Build/Intermediates/SwiftShell.build/Release/SwiftShell.build/Objects-normal/x86_64/FileHandle.d''. Error: Error Domain=NSCocoaErrorDomain Code=260 "The file “FileHandle.d” couldn’t be opened beca |
#!/bin/sh | |
# | |
# From http://stackoverflow.com/questions/17964660/how-to-detect-if-user-is-away-in-osx | |
# | |
ioreg -c IOHIDSystem | awk '/HIDIdleTime/ {print $NF/1000000000; exit}' |
<?php | |
/* | |
Install: | |
1) create a folder: disablecsrf inside 'plugins/' directory. | |
2) place this file there and name it: disablecsrf.php | |
3) go to config/config.inc.php, and add it to plugins, like: | |
$config['plugins'] = array('disablecsrf'); | |
CSRF should now be disabled for login. | |
*/ |
<?php | |
//absolute path to wp-load.php, or relative to this script | |
//e.g., ../wp-core/wp-load.php | |
include( 'trunk/wp-load.php' ); | |
//grab the WPDB database object, using WP's database | |
//more info: http://codex.wordpress.org/Class_Reference/wpdb | |
global $wpdb; |
<?php | |
// Load WordPress | |
require_once 'path/to/www/wp-load.php'; | |
require_once ABSPATH . '/wp-admin/includes/taxonomy.php'; | |
// Set the timezone so times are calculated correctly | |
date_default_timezone_set('Europe/London'); | |
// Create post |
#!/bin/bash | |
while [ 1 ]; do | |
echo -n "red" | nc -4u -w0 localhost 1738 ; sleep 1; echo -n "white" | nc -4u -w0 localhost 1738; sleep 1; | |
done | |
# onliner | |
# while [ 1 ]; do echo -n "red" | nc -4u -w0 localhost 1738 ; sleep 1; echo -n "white" | nc -4u -w0 localhost 1738; sleep 1; done |