This file contains hidden or 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
#import <Foundation/Foundation.h> | |
int main(int argc, const char* argv[]) | |
{ | |
NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init]; | |
NSAppleScript* script = [[NSAppleScript alloc] initWithSource:@"tell application \"Finder\"\nclean up window of desktop\nend tell"]; | |
while ( true ) | |
{ |
This file contains hidden or 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
/* | |
display-brightness.c | |
gcc -o display-brightness display-brightness.c \ | |
-framework IOKit -framework ApplicationServices | |
*/ | |
#include <stdio.h> | |
#include <IOKit/graphics/IOGraphicsLib.h> | |
#include <ApplicationServices/ApplicationServices.h> |
This file contains hidden or 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
#import <Foundation/Foundation.h> | |
int main(int argc, const char* argv[]) | |
{ | |
NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init]; | |
NSAppleScript* script = [[NSAppleScript alloc] initWithSource:@"tell application \"Finder\"\nclean up window of desktop\nend tell"]; | |
while ( true ) | |
{ |
This file contains hidden or 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
#!/usr/bin/env python2 | |
import gdata.photos.service | |
import getpass | |
import sys | |
import os.path | |
from optparse import OptionParser | |
def main(): | |
parser = OptionParser(usage="usage: %prog [options] images...", version="%prog v0.1.0") |
This file contains hidden or 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
// gcc -Wall -W -Wno-unused-parameter -Werror -arch i386 -arch ppc main.c -framework CoreServices -o cb | |
// cb service to respond to an action upon dir change. great starting point. | |
#include <CoreServices/CoreServices.h> | |
#define EVENT_STREAM_LATENCY ((CFAbsoluteTime)5) | |
const char *command; | |
void build( |
This file contains hidden or 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 | |
# | |
# Author: Andreas Olsson <[email protected]> | |
# Version: @(#)autossh_tunnel.foo 0.1 27-Aug-2008 [email protected] | |
# | |
# For each tunnel; make a uniquely named copy of this template. | |
## SETTINGS | |
# |
This file contains hidden or 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
// gcc -framework ApplicationServices -framework CoreFoundation -framework IOKit display.c -o display | |
/* This code was based on SetDisplay from the University of Utah Student | |
* Computing Labs. | |
* The code has since been modified by Rob Braun ([email protected]) | |
* Please do not contact Utah Student Computing Labs with problems with | |
* this software. I probably introduced them. | |
*/ | |
/* |
This file contains hidden or 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 'formula' | |
class Cpansearch <Formula | |
head 'http://github.com/c9s/cpansearch.git', :using => :git | |
homepage 'http://github.com/c9s/cpansearch' | |
# Don't take +x off these files | |
skip_clean 'bin' | |
# uses libcurl (system) |
This file contains hidden or 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
/* | |
asynctask.m -- sample code that shows how to implement asynchronous stdin, stdout & stderr streams for processing data with NSTask | |
compile with: | |
gcc -Wall -O3 -x objective-c -fobjc-exceptions -framework Foundation -o asynctask asynctask.m | |
./asynctask | |
./asynctask > asynctask-output.txt 2>&1 |
This file contains hidden or 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
// -*- c-basic-offset:2; tab-width:8; -*- | |
/* | |
* change-bundle-id.m | |
* | |
* Created by Chris Suter on 16/5/2008. | |
* Copyright 2008 Coriolis Systems. All rights reserved. | |
* | |
*/ | |
#import <Foundation/Foundation.h> |