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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<style> | |
.feld1 { | |
margin: 20px; | |
} | |
.feld2 { |
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/bash | |
exec &> ~/.sleep.log | |
# Author: [email protected] | |
# Version: 0.0.1 | |
echo ".sleep triggered at $(date)" | |
# This have to be here otherwise launchctl won't find Docker commands | |
DOCKER=/usr/local/bin/docker |
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
- (IBAction)buttonTapped:(UIButton *)aSender { | |
self.validationErrors = nil; | |
// Translate Button -> Option | |
NSUInteger index = [self.buttonsView.subviews indexOfObject:aSender]; | |
PQMarkSheetAnswer *selectedOption = (self.options)[index]; | |
// When we have single choice we need to toggle options | |
if (!self.allowsMultipleSelection && [self.selectedOptions count] > 0) { | |
PQMarkSheetAnswer *alreadySelectedOption = [self.selectedOptions firstObject]; |
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
<!doctype html> | |
<html lang="en_GB"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Content</title> | |
<script type="text/javascript" src="./print.js"></script> | |
<style> | |
/* Page layout, header, footer */ | |
body { |
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
angular | |
.module("core.analytics", []) | |
.service("Analytics", function($rootScope, $state){ | |
this.handle = null; | |
this.setup = function(handle, trackerID){ | |
if (!handle) { | |
console.log("Analytics: Unable to initialize plugin!"); | |
return false; |
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
/** | |
* Authentication session handling token and user id | |
*/ | |
angular.module('fn.services.authentication', []) | |
.service('srvAuthenticationSession', ['$window', function ($window) { | |
this.save = function() { | |
var data = {'userId':this.userId, 'token':this.token}; | |
$window.localStorage['com.fansnation.authorisationSession'] = JSON.stringify(data); | |
} |
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
require 'rubygems' | |
require 'bundler/setup' | |
require 'sinatra' | |
require 'securerandom' | |
NOTES = {} | |
get '/' do | |
response = '<html><body>' | |
response << %Q{<h1>Create secret note</h1>} |
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
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> | |
<!DOCTYPE hheaTable [ | |
<!ELEMENT hheaTable EMPTY> | |
<!ATTLIST hheaTable versionMajor CDATA #IMPLIED | |
versionMinor CDATA #IMPLIED | |
ascender CDATA #IMPLIED | |
descender CDATA #IMPLIED | |
lineGap CDATA #IMPLIED | |
advanceWidthMax CDATA #IMPLIED | |
minLeftSideBearing CDATA #IMPLIED |
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
- (BOOL)connection:(NSURLConnection *)connection canAuthenticateAgainstProtectionSpace:(NSURLProtectionSpace *)protectionSpace { | |
return [protectionSpace.authenticationMethod isEqualToString:NSURLAuthenticationMethodServerTrust]; | |
} | |
- (void)connection:(NSURLConnection *)connection didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge { | |
if ([challenge.protectionSpace.authenticationMethod isEqualToString:NSURLAuthenticationMethodServerTrust]) | |
if ([[[GJEnvironment sharedEnvironment] trustedHosts] containsObject:challenge.protectionSpace.host]) | |
[challenge.sender useCredential:[NSURLCredential credentialForTrust:challenge.protectionSpace.serverTrust] forAuthenticationChallenge:challenge]; | |
[challenge.sender continueWithoutCredentialForAuthenticationChallenge:challenge]; |
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
module PK | |
module Filter | |
class Juice < Nanoc3::Filter | |
identifier :juice | |
type :text | |
def run(content, params={}) | |
input_filename = File.join('content', @item.path) | |
output_filename = File.absolute_path(File.join('tmp', "#{@item.path}")) |
NewerOlder