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 YouTubeIt::Upload::VideoUpload | |
def comments_with_meta(video_id_or_url, opts = {}) | |
url = if video_id_or_url.start_with?('http') | |
video_id_or_url | |
else | |
comment_url = "/feeds/api/videos/%s/comments?" % video_id_or_url | |
comment_url << opts.collect { |k, p| [k, p].join '=' }.join('&') | |
end | |
response = yt_session.get(url) | |
comments = YouTubeIt::Parser::CommentsFeedParser.new(response).parse |
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
begin | |
require 'bundler/inline' | |
rescue LoadError => e | |
$stderr.puts 'Bundler version 1.10 or later is required. Please update your Bundler' | |
raise e | |
end | |
gemfile(true) do | |
source 'https://rubygems.org' | |
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
begin | |
require 'bundler/inline' | |
rescue LoadError => e | |
$stderr.puts 'Bundler version 1.10 or later is required. Please update your Bundler' | |
raise e | |
end | |
gemfile(true) do | |
source 'https://rubygems.org' | |
# Rails 4.2 throws an exception on last test case |
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
ruby dotNetHash.rb password123 LU7hUk4MXAvlq6DksvP9SQ== | |
require "base64" | |
require “digest” | |
# Encode password as double-width characters | |
password_as_text = ARGV.first | |
double_width_password = [] | |
double_width_password = password_as_text.encode("UTF-16LE").bytes.to_a | |
# Unencode the salt |
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
--- | |
id: 1 | |
type: book | |
awards: | |
books: | |
- id: 1 | |
title: International Botev | |
reviewers: | |
- id: 2 | |
name: PersonB |
OlderNewer