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
set -e | |
mock() { | |
local cmd="$1" | |
local args="$2" | |
local ret="$3" | |
eval "$(echo -e " | |
$cmd() { | |
local args=\"\$*\" |
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
#!/usr/bin/env bats | |
load test_helper | |
setup() { | |
success() { | |
echo $1 | |
exit 0 | |
} |
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
Dir.glob(rake_files).each do |task| | |
Rake.load_rakefile(task) | |
# | |
# filename_without_ext = File.basename(task.sub(/.rake$/, '')) | |
# Rake.application.rake_require(filename_without_ext, [File.dirname(task).to_s], loaded_files) | |
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
# A sample Gemfile | |
source "https://rubygems.org" | |
gem "fb_graph" | |
gem "pry" |
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
<div class="container"> | |
<% if flash[:notice] %> | |
<div class="alert alert-success"> | |
<%= flash[:notice] %> | |
</div> | |
<% end %> | |
<h1>Users</h1> | |
<%= form_for(@user_import, url: import_admin_users_path, | |
html: {method: :post, multipart: true, role: "form", class: "form-inline"}) do |f| %> |
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('underscore') | |
request = require('request') | |
Yammer = new require('yammer').Yammer | |
# user list | |
# yam.users (res, users) -> | |
# _.each users, (user) -> | |
# console.log("#{user.id} => #{user.full_name}") | |
class Slack |
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 | |
# <description of the scripts functionality> | |
# | |
# Dependencies: | |
# "<module name>": "<module version>" | |
# | |
# Configuration: | |
# LIST_OF_ENV_VARS_TO_SET | |
# | |
# 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
Robot = require("hubot/src/robot") | |
TextMessage = require("hubot/src/message").TextMessage | |
path = require 'path' | |
chai = require 'chai' | |
sinon = require 'sinon' | |
chai.use require 'sinon-chai' | |
expect = chai.expect |
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
= render 'shared/error_messages', :target => @user_import | |
%fieldset | |
= form_for @user_import, {url: import_admin_user_path, html: {method: :put, multipart: true}} do |f| | |
= f.label "ユーザーファイル" | |
= f.file_field :file | |
%span.form-buttons | |
= button "アップロード" |