-
liblinear-ruby: Ruby interface to LIBLINEAR using SWIG
-
classifier-reborn: Bayesian and LSI classification
dependencies: GSL
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 AnyFixture | |
| INSERT_RXP = /^INSERT INTO ([\S]+)/ | |
| class Cache | |
| attr_reader :store | |
| delegate :clear, to: :store | |
| def initialize | |
| @store = {} |
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
| #!/usr/bin/env ruby | |
| require "openssl" | |
| require 'digest/sha2' | |
| require 'base64' | |
| # We use the AES 256 bit cipher-block chaining symetric encryption | |
| alg = "AES-256-CBC" | |
| # We want a 256 bit key symetric key based on some passphrase | |
| digest = Digest::SHA256.new |
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
| function reloadCSS() { | |
| const links = document.getElementsByTagName('link'); | |
| Array.from(links) | |
| .filter(link => link.rel.toLowerCase() === 'stylesheet' && link.href) | |
| .forEach(link => { | |
| const url = new URL(link.href, location.href); | |
| url.searchParams.set('forceReload', Date.now()); | |
| link.href = url.href; | |
| }); |
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 good commit message looks like this: | |
| Header line: explaining the commit in one line | |
| Body of commit message is a few lines of text, explaining things | |
| in more detail, possibly giving some background about the issue | |
| being fixed, etc etc. | |
| The body of the commit message can be several paragraphs, and | |
| please do proper word-wrap and keep columns shorter than about |
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
| function rmb { | |
| current_branch=$(git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/') | |
| if [ "$current_branch" != "master" ]; then | |
| echo "WARNING: You are on branch $current_branch, NOT master." | |
| fi | |
| echo "Fetching merged branches..." | |
| git remote prune origin | |
| remote_branches=$(git branch -r --merged | grep -v '/master$' | grep -v "/$current_branch$") | |
| local_branches=$(git branch --merged | grep -v 'master$' | grep -v "$current_branch$") | |
| if [ -z "$remote_branches" ] && [ -z "$local_branches" ]; then |
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
| # rubocop config files for small Rails4/Ruby2 project | |
| # blog post: http://joanswork.com/rubocop-rails-getting-started/ | |
| # .rubocop.yml | |
| AllCops: | |
| Include: | |
| - Rakefile | |
| - config.ru | |
| Exclude: |
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
| namespace :deploy do | |
| Rake::Task["deploy:compile_assets"].clear_actions | |
| task :compile_assets => [:set_rails_env] do | |
| run_locally do | |
| if capture("git --no-pager diff #{fetch(:previous_revision)} #{fetch(:current_revision)} app/assets vendor/assets").empty? | |
| info "Skipping assets compilation" | |
| else | |
| invoke 'deploy:assets:precompile' | |
| invoke 'deploy:assets:backup_manifest' | |
| end |
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
| ## From Lynda.com course 'RSpec Testing Framework with Ruby' | |
| describe 'Expectation Matchers' do | |
| describe 'equivalence matchers' do | |
| it 'will match loose equality with #eq' do | |
| a = "2 cats" | |
| b = "2 cats" | |
| expect(a).to eq(b) |
UPDATE 2014-12-21: RubyGems 1.8.30, 2.0.15 and 2.2.3 have been released. It requires manual installation, please see instructions below.
Hello,
If you reached this page, means you've hit this SSL error when trying to