2.4.2 :038 > 'åäöÅÄÖ'.unicode_normalize(:nfd).scan(/\X/)
=> ["å", "ä", "ö", "Å", "Ä", "Ö"]
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 Opener | |
| module Core | |
| module Syslog | |
| def self.enabled? | |
| false | |
| end | |
| end | |
| end | |
| 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
| 263,264c263 | |
| < # Net::HTTP.start(uri.host, uri.port, | |
| < # :use_ssl => uri.scheme == 'https') do |http| | |
| --- | |
| > # Net::HTTP.start(uri.host, uri.port, :use_ssl => true) do |http| | |
| 266d264 | |
| < # | |
| 269a268,274 | |
| > # Or if you simply want to make a GET request, you may pass in an URI | |
| > # object that has a HTTPS URL. Net::HTTP automatically turn on TLS |
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 "rubygems" | |
| require "celluloid" | |
| require "pry" | |
| module Enumerable | |
| class ComutativeReducerActor | |
| include Celluloid | |
| def initialize(enumerable, reducer) | |
| @enumerable = enumerable |
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 -w | |
| # Implementation | |
| BACKTRACE_REGEX = /^(.+?):(\d+)(?::in `(.+?)')?$/.freeze | |
| def strip_load_path path | |
| prefix = $: | |
| .map(&:to_s) | |
| .select { |s| path.start_with?(s) } |
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
| GEM | |
| remote: https://rubygems.org/ | |
| specs: | |
| bcrypt (3.1.11) | |
| diff-lcs (1.2.5) | |
| rake (12.0.0) | |
| rspec (3.5.0) | |
| rspec-core (~> 3.5.0) | |
| rspec-expectations (~> 3.5.0) | |
| rspec-mocks (~> 3.5.0) |
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
| #!/bin/bash | |
| # Script to bisect to the right JRuby | |
| # | |
| # 9.1.2.0 works | |
| # 9.1.3.0 does not work | |
| # | |
| # https://git-scm.com/docs/git-bisect | |
| # | |
| # Build JRuby, bundle install, then rspec | |
| # |
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 -G --dev | |
| $: << __dir__ | |
| require 'java' | |
| require 'jdbc/postgres' | |
| require 'sequel' | |
| require 'sequel/adapters/jdbc' | |
| require 'thread' | |
| # Pre-requisite: Set up a failing "SQL server" to not connect to | |
| # |
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
| Using Sequel with the jdbc adapter, I got a: | |
| ``` | |
| NoMethodError: undefined method `message=' for #<Java::JavaSql::SQLException:0x37daf0d> | |
| ``` | |
| on the line [sequel-4.38.0/lib/sequel/adapters/jdbc.rb:227:in `connect'](https://github.com/jeremyevans/sequel/blob/master/lib/sequel/adapters/jdbc.rb#L225) | |
| If the re-caught error, `e2`, `is_a?(Java::JavaSql::SQLException)`, could it do something else? |
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
| en verden | |
| stablet i dobletter | |
| med referater til kopi | |
| organiseret i jatekker | |
| med handleplaner indeni | |
| alt --- | |
| tvunget til fængsel uden dom | |
| i en fortagende raison-d'etre | |
| støbt i rener af beton |