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
# A quick example of a Twitch chat bot in Ruby. | |
# No third party libraries. Just Ruby standard lib. | |
# | |
# See the tutorial video: https://www.youtube.com/watch?v=_FbRcZNdNjQ | |
# | |
# You can fill in creds here or use environment variables if you choose. | |
TWITCH_CHAT_TOKEN = ENV['TWITCH_CHAT_TOKEN'] | |
TWITCH_USER = ENV['TWITCH_USER'] |
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 'socket' | |
require 'rack' | |
require 'sinatra' | |
# Simple, rack-compliant web server | |
class MyServer | |
STATUS_CODES = { | |
200 => 'OK', | |
500 => 'Internal Server Error' | |
} |
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
module MethodTracing | |
class Tracer | |
class << self | |
attr_reader :tracers | |
end | |
@tracers = {} | |
attr_accessor :count | |
attr_reader :target |
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
" dart setup | |
autocmd FileType dart set errorformat+=%.%#\\\|%.%#\\\|%.%#\\\|%f\\\|%l\\\|%c\\\|%.%#\\\|%m | |
autocmd FileType dart set makeprg=dartanalyzer\ --machine\ % | |
autocmd BufWritePre *.dart Make | |
let g:syntastic_mode_map = { "mode": "active", | |
\ "passive_filetypes": ["dart"] } |