Skip to content

Instantly share code, notes, and snippets.

View lkraider's full-sized avatar

Paul Eipper lkraider

View GitHub Profile
@arsdehnel
arsdehnel / iam-terraform-create-policy.tf
Last active September 21, 2023 18:12
AWS IAM policies for running Terraform from an EC2 instance.
resource "aws_iam_policy" "terraform_create_policy" {
name = "terraform_create_policy"
path = "/"
policy = "${data.aws_iam_policy_document.terraform_create_policy.json}"
}
data "aws_iam_policy_document" "terraform_create_policy" {
statement {
sid = "1"
actions = [
@tjanez
tjanez / reproducibility-test.sh
Last active May 2, 2020 11:50
Script to test reproducibility of git-archive-all.sh and git's built-in archive command
#!/bin/bash
# Script to test reproducibility of git-archive-all.sh and git's built-in
# archive command
#
# Usage:
# 1. Copy the script to your git directory with submodules.
# 2. Download the git-archive-all.sh script:
# https://raw.githubusercontent.com/meitar/git-archive-all.sh/master/git-archive-all.sh
# and place it somewhere in your $PATH and make it executable.
@tvervest
tvervest / ExtendedBarButtonItem.h
Created January 30, 2014 13:38
A drop-in replacement for the UIBarButtonItem class which passes the set target and action to the custom view if it is a UIControl. As I grew tired of having to pay attention to UIBarButtonItem objects having custom (control) views, I wrote an extending class which actually behaves the way (I think) the parent class should. All you have to do is…
//
// ExtendedBarButtonItem.h
//
// Created by Thomas Vervest.
// This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
// http://creativecommons.org/licenses/by-sa/4.0/
//
#import <UIKit/UIKit.h>
@vitkin
vitkin / README.md
Last active August 5, 2021 19:19
Backport WebSocket to Apache 2.2 that doesn't modify the 'mod_utils.c' and the 'mod_proxy.h'. See the 'README.md' for details and instructions.

Backport WebSocket to Apache 2.2

This is my variation from the original patch and that also includes the suggested correction for the bug with secure websocket 'wss://'.

The difference is that I avoid modifying the mod_utils.c and the mod_proxy.h so that if the mod_proxy module has been embedded in the main httpd binary then it will work and you won't get the

@nuthatch
nuthatch / NSManagedObject+Serialization.h
Last active May 8, 2019 11:25 — forked from pkclsoft/NSManagedObject+Serialization.h
Fixes for Peter Easdown's category 1. don't assume each Entity name matches the Class name. 2. strip DATE_ATTR_PREFIX when deserializing dates back into NSManagedObject 3. add support for NSOrderedSet 4. use set to keep traversal history, and allow classes to opt-out with serializationObjectsToSkip
@interface NSManagedObject (Serialization)
- (NSDictionary*) toDictionary;
- (void) populateFromDictionary:(NSDictionary*)dict;
+ (NSManagedObject*) createManagedObjectFromDictionary:(NSDictionary*)dict
inContext:(NSManagedObjectContext*)context;
@end
anonymous
anonymous / main.py
Created August 24, 2012 14:40
BrubeckMySQL Implementation Details
## Just the relevant parts here
...
project_dir = '.'
config = {
...
'settings_file': project_dir + '/config/salesbus/settings.py',
...
}
@fxthomas
fxthomas / ilocalize.py
Created May 7, 2012 10:32
iLocalize -- Xcode project localizer
#!/usr/bin/python
# coding=utf-8
# Base Python File (ilocalize.py)
# Created: Sun May 6 11:18:15 2012
# Version: 1.0
#
# This Python script was developped by François-Xavier Thomas.
# You are free to copy, adapt or modify it.
# If you do so, however, leave my name somewhere in the credits, I'd appreciate it ;)
@0xced
0xced / install-iphone-sdk-3.1.3.sh
Created September 13, 2010 18:43
Install iPhone SDK 3.1.3 script
#!/bin/bash -e
# More information at http://0xced.blogspot.com/2010/07/using-sdk-313-with-iphone-sdk-4.html
IPHONE_SDK_DMG="$HOME/Downloads/iphone_sdk_3.1.3_with_xcode_3.2.1__snow_leopard__10m2003a.dmg"
DEVELOPER_DIR="/Developer"
MOUNT_POINT="/Volumes/iPhone SDK"
function cleanup
{
echo ""