Skip to content

Instantly share code, notes, and snippets.

Avatar
💻

Eneko Alonso eneko

💻
View GitHub Profile
@masaki
masaki / gist:1238005
Created Sep 23, 2011
PhantomJS on CentOS-5
View gist:1238005
# SEE: http://d.hatena.ne.jp/shim0mura/20110730/1312046133
# SEE: https://gist.github.com/1031961
# SEE: http://atrpms.net/documentation/install/
# 1. prepare
$ cat /etc/yum.repos.d/atrpms.repo
[atrpms-stable]
name=ATrpms RHEL5 stable
baseurl=http://dl.atrpms.net/el5-$basearch/atrpms/stable/
gpgkey=http://ATrpms.net/RPM-GPG-KEY.atrpms
@kirpit
kirpit / bash.py
Last active Nov 18, 2021
Enables to run subprocess commands in a different thread with TIMEOUT option!
View bash.py
#! /usr/bin/env python
import threading
import subprocess
import traceback
import shlex
class Command(object):
"""
Enables to run subprocess commands in a different thread with TIMEOUT option.
@jobliz
jobliz / RedisPythonPubSub1.py
Created May 4, 2012
A short script exploring Redis pubsub functions in Python
View RedisPythonPubSub1.py
import redis
import threading
class Listener(threading.Thread):
def __init__(self, r, channels):
threading.Thread.__init__(self)
self.redis = r
self.pubsub = self.redis.pubsub()
self.pubsub.subscribe(channels)
@jhjguxin
jhjguxin / creating-nested-resources-in-ruby-on-rails-3-and-updating-scaffolding-links-and-redirection.markdown
Created Jul 9, 2012
Creating nested resources in ruby on rails 3 and updating scaffolding links and redirection
View creating-nested-resources-in-ruby-on-rails-3-and-updating-scaffolding-links-and-redirection.markdown
@johanneswuerbach
johanneswuerbach / .travis.yml
Last active Mar 25, 2021
Deploy an iOS app to testflight using Travis CI
View .travis.yml
---
language: objective-c
before_script:
- ./scripts/travis/add-key.sh
after_script:
- ./scripts/travis/remove-key.sh
after_success:
- ./scripts/travis/testflight.sh
env:
global:
@davidjrice
davidjrice / .travis.yml
Last active Oct 23, 2019 — forked from johanneswuerbach/.travis.yml
Travis CI + TestFlight integration (updated for Travis' new Mac VM setup / xctool)
View .travis.yml
language: objective-c
xcode_workspace: "<WorkspaceName.xcworkspace>"
xcode_scheme: "<SchemaName>"
script: xctool -workspace <WorkspaceName.xcworkspace> -scheme <SchemeName> -configuration Release build archive
before_script:
- ./scripts/travis/add-key.sh
after_script:
- ./scripts/travis/remove-key.sh
after_success:
- ./scripts/travis/testflight.sh
View grouper_interactor_example.rb
class GroupersController < ApplicationController::Base
def create
@grouper = Grouper.new(leader: current_member)
if @grouper.save
confirm_grouper_via_emails(@grouper)
enqueue_bar_assignment(@grouper)
redirect_to home_path
else
@rodneyrehm
rodneyrehm / gist:40e7946c0cff68a31cea
Last active Oct 22, 2021
Diagrams for Documentation
View gist:40e7946c0cff68a31cea

some tools for diagrams in software documentation

Diagrams For Documentation

Obvious Choices

ASCII

@duemunk
duemunk / Guilty
Last active Jun 23, 2016
Operator overload badge
View Guilty
<img src="http://img.shields.io/badge/Operator_overload-guilty-red.svg" height="20" alt="Uses operator overloads"/>
@s-aska
s-aska / Keychain.swift
Last active Aug 25, 2020
Swift Keychain class ( supported Xcode 6.0.1 )
View Keychain.swift
import UIKit
import Security
class Keychain {
class func save(key: String, data: NSData) -> Bool {
let query = [
kSecClass as String : kSecClassGenericPassword as String,
kSecAttrAccount as String : key,
kSecValueData as String : data ]