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
function extend(table1, table2) | |
for k,v in pairs(table2) do | |
if (type(table1[k]) == 'table' and type(v) == 'table') then | |
extend(table1[k], v) | |
else | |
table1[k] = v | |
end | |
end | |
end |
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 | |
# Installation: | |
# | |
# 1. vim /etc/ssh/sshd_config | |
# PrintMotd no | |
# | |
# 2. vim /etc/pam.d/login | |
# # session optional pam_motd.so | |
# |
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
function array_extend() { | |
$arrays = func_get_args(); | |
$base = array_shift($arrays); | |
foreach ($arrays as $array) { | |
reset($base); | |
while (list($key, $value) = @each($array)) | |
if (is_array($value) && @is_array($base[$key])) | |
$base[$key] = array_extend($base[$key], $value); | |
else $base[$key] = $value; | |
} |
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
/** | |
* The entrance transition module. | |
* @module entrance | |
* @requires system | |
* @requires composition | |
* @requires jquery | |
*/ | |
define(['durandal/system', 'durandal/composition', 'jquery'], function(system, composition, $) { | |
var fadeOutDuration = 100; | |
var endValues = { |
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
# Description: | |
# Polls the rss feeds and posts new content to the user or group chat. | |
# | |
# Dependencies: | |
# "feed-read": "0.0.1" | |
# | |
# Configuration: | |
# None | |
# | |
# Commands: |
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
# Description: | |
# Post to a channel when a steam account starts a game. | |
# | |
# Commands: | |
# | |
# Configuration: | |
# STEAM_API_KEY: Steam community api key to access steam accounts. | |
# STEAM_USER_ID: The steam user id in which to monitor. | |
# STEAM_POST_CHANNEL_NAME: The channel to post to when the user starts playing. | |
# |
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
# config/application.rb | |
require_relative 'boot' | |
require 'rails/all' | |
# Require the gems listed in Gemfile, including any gems | |
# you've limited to :test, :development, or :production. | |
Bundler.require(*Rails.groups) |
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
/** | |
* TYPES ======================================================= | |
*/ | |
export interface MyResourcesState extends EntityState<MyResource> { | |
getAllLoading: boolean; | |
getAllLoaded: boolean; | |
getAllLoadedError: Error | null; | |
} | |
/** |