This document provides a comprehensive overview of all available configuration options for OpenCode, including command-line flags, environment variables, and configuration file 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
| # Add your own tasks in files placed in lib/tasks ending in .rake, | |
| # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. | |
| require(File.join(File.dirname(__FILE__), 'config', 'boot')) | |
| require 'rake' | |
| require 'rake/testtask' | |
| require 'rake/rdoctask' | |
| require 'tasks/rails' |
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 'deferrable_gratification' | |
| class Promise | |
| def initialize | |
| @df = EM::DefaultDeferrable.new | |
| DG.enhance! EM::DefaultDeferrable | |
| end | |
| def done(&block) | |
| tap { @df.callback(&block) } |
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 'rubycocoa' | |
| ##### begin from drb/invokemethod.rb | |
| module DRb | |
| class DRbServer | |
| module InvokeMethod18Mixin | |
| def block_yield(x) | |
| if x.size == 1 && x[0].class == Array | |
| x[0] = DRbArray.new(x[0]) | |
| end |
Hey
The journey from the first simple bots to superhuman AI like Libratus and Pluribus is a fascinating 27-year story of academic rivalries, commercial scandals, and massive algorithmic breakthroughs. It's a perfect case study in AI for imperfect information games.
I've written up a little history, from the first academic attempts in 1998 to the modern "GTO Solvers." Grab a coffee, this is a long one.
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
| class Contact < ActiveRecord::Base | |
| ... | |
| def after_create | |
| if Hook.hooks_exist?('new_contact', self) | |
| Resque.enqueue(Hook, self.class.name, self.id) | |
| # To trigger directly without Resque: Hook.trigger('new_contact', self) | |
| end | |
| end |
Improved YARD CHEATSHEET http://yardoc.org
forked from https://gist.github.com/chetan/1827484 which is from early 2012 and contains outdated information.
Templates to remind you of the options and formatting for the different types of objects you might want to document using YARD.
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
| # Basic key operators to query the JSON objects : | |
| # #> : Get the JSON object at that path (if you need to do something fancy) | |
| # -> : Get the JSON object at that path (if you don't) | |
| # ->> : Get the JSON object at that path as text | |
| # {obj, n} : Get the nth item in that object | |
| # https://www.postgresql.org/docs/9.4/functions-json.html#FUNCTIONS-JSONB-OP-TABLE | |
| # Date | |
| # date before today |
This is all you really need to know in order to make Action Mailbox work in development.
- Fire up
ngrok http 3000and make note of your subdomain for steps 3 and 8. - Create a Mailgun account because they offer sandbox addresses; grab your domain from the Dashboard.
- Go into Receiving and create a catch-all route pointing to:
https://XXX.ngrok.io/rails/action_mailbox/mailgun/inbound_emails/mime - Add your Mailgun API key to your credentials:
action_mailbox:
mailgun_api_key: API KEY HERE