repo_name
stringlengths
6
97
path
stringlengths
3
341
text
stringlengths
8
1.02M
gxbsst/pbl_service_client
lib/pbl/base/response/extra_response.rb
module Pbl module Base module ExtraResponse include Virtus.module attribute :code, Integer attribute :headers, String attribute :body, String def success? if /^2[0-9][0-9]$/.match(self.code.to_s) true else false end end def d...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/lists_test.rb
require 'test_helper' context "Bulleted lists (:ulist)" do context "Simple lists" do test "dash elements with no blank lines" do input = <<-EOS List ==== - Foo - Boo - Blech EOS output = render_string input assert_xpath '//ul', output, 1 assert_xpath '//ul/li', output, 3 end ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/backends/html5.rb
module Asciidoctor class BaseTemplate # create template matter to insert a style class from the role attribute if specified def role_class attrvalue(:role) end # create template matter to insert a style class from the style attribute if specified def style_class(sibling = true) attrvalue(:style, sib...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/links_test.rb
require 'test_helper' context 'Links' do test 'qualified url inline with text' do assert_xpath "//a[@href='http://asciidoc.org'][text() = 'http://asciidoc.org']", render_string("The AsciiDoc project is located at http://asciidoc.org.") end test 'qualified url with label' do assert_xpath "//a[@href='htt...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/section.rb
<filename>src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/section.rb<gh_stars>0 module Asciidoctor # Public: Methods for managing sections of AsciiDoc content in a document. # The section responds as an Array of content blocks by delegating # block-related methods to its @blocks Array. # # Examples...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/backends/docbook45.rb
module Asciidoctor class BaseTemplate def tag(name, key) type = key.is_a?(Symbol) ? :attr : :var key = key.to_s if type == :attr # example: <% if attr? 'foo' %><bar><%= attr 'foo' %></bar><% end %> %(<% if attr? '#{key}' %><#{name}><%= attr '#{key}' %></#{name}><% end %>) e...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/cli/invoker.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin module Asciidoctor module Cli # Public Invocation class for starting Asciidoctor via CLI class Invoker attr_reader :options attr_reader :document attr_reader :code attr_reader :timings def initialize(*options) @document = ni...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/blocks_test.rb
require 'test_helper' require 'pathname' context "Blocks" do context 'Line Breaks' do test "ruler" do output = render_string("'''") assert_xpath '//*[@id="content"]/hr', output, 1 assert_xpath '//*[@id="content"]/*', output, 1 end test "ruler between blocks" do output = render_st...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/helpers.rb
<filename>src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/helpers.rb module Asciidoctor module Helpers # Internal: Prior to invoking Kernel#require, issues a warning urging a # manual require if running in a threaded environment. # # name - the String name of the library to require. # ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/errors.rb
<filename>src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/errors.rb # Base project exception module Asciidoctor class ProjectError < StandardError; end end
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/block.rb
module Asciidoctor # Public: Methods for managing blocks of Asciidoc content in a section. # # Examples # # block = Asciidoctor::Block.new(document, :paragraph, ["`This` is a <test>"]) # block.content # => ["<em>This</em> is a &lt;test&gt;"] class Block < AbstractBlock # Public: Create alias for context to be ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/sections_test.rb
<filename>src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/sections_test.rb # encoding: UTF-8 require 'test_helper' context 'Sections' do context 'Ids' do test 'synthetic id is generated by default' do sec = block_from_string('== Section One') assert_equal '_section_one', sec.id end ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/renderer.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin module Asciidoctor # Public: Methods for rendering Asciidoc Documents, Sections, and Blocks # using eRuby templates. class Renderer attr_reader :compact # Public: Initialize an Asciidoctor::Renderer object. # def initialize(options={}) @debug = !!options[:debu...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/substituters.rb
<gh_stars>0 module Asciidoctor # Public: Methods to perform substitutions on lines of AsciiDoc text. This module # is intented to be mixed-in to Section and Block to provide operations for performing # the necessary substitutions. module Substituters COMPOSITE_SUBS = { :none => [], :normal => [:specialcharac...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/lexer.rb
<filename>src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/lexer.rb<gh_stars>0 module Asciidoctor # Public: Methods to parse lines of AsciiDoc into an object hierarchy # representing the structure of the document. All methods are class methods and # should be invoked from the Lexer class. The main e...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/execute_asciidoctor.rb
require 'bundler/setup' require 'asciidoctor' Dir.glob("#{$srcDir}/**/*.a*").each do |path| if path =~ /.*\.a((sc(iidoc)?)|d(oc)?)$/ Asciidoctor.render_file(path, {:in_place => false, :safe => Asciidoctor::SafeMode::UNSAFE, :attributes => {'backend' => $backend}, :to_dir => $ou...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/document_test.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin require 'test_helper' context 'Document' do context 'Example document' do test 'document title' do doc = example_document(:asciidoc_index) assert_equal 'AsciiDoc Home Page', doc.doctitle assert_equal 'AsciiDoc Home Page', doc.name assert_equ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/reader.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin<filename>src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/reader.rb module Asciidoctor # Public: Methods for retrieving lines from AsciiDoc source files class Reader # Public: Get the document source as a String Array of lines. attr_reader :source ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/options_test.rb
require 'test_helper' require 'asciidoctor/cli/options' context 'Options' do test 'should return error code 0 when help flag is present' do redirect_streams do |stdout, stderr| exitval = Asciidoctor::Cli::Options.parse!(%w(-h)) assert_equal 0, exitval assert_match(/^Usage:/, stdout.string) ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/invoker_test.rb
require 'test_helper' require 'asciidoctor/cli/options' require 'asciidoctor/cli/invoker' context 'Invoker' do test 'should parse source and render as html5 article by default' do invoker = nil output = nil redirect_streams do |stdout, stderr| invoker = invoke_cli %w(-o -) output = stdout.str...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/lexer_test.rb
require 'test_helper' context "Lexer" do test "is_section_title?" do assert Asciidoctor::Lexer.is_section_title?('AsciiDoc Home Page', '==================') assert Asciidoctor::Lexer.is_section_title?('=== AsciiDoc Home Page') end test "collect unnamed attribute" do attributes = {} line = 'quot...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/document.rb
module Asciidoctor # Public: Methods for parsing Asciidoc documents and rendering them # using erb templates. # # There are several strategies for getting the title of the document: # # doctitle - value of title attribute, if assigned and non-empty, # otherwise title of first section in document, if present ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/renderer_test.rb
require 'test_helper' context 'Renderer' do test 'should extract view mapping from built-in template with one segment and backend' do view_name, view_backend = Asciidoctor::Renderer.extract_view_mapping('Asciidoctor::HTML5::DocumentTemplate') assert_equal 'document', view_name assert_equal 'html5', vie...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/paragraphs_test.rb
<gh_stars>0 require 'test_helper' context "Paragraphs" do context 'Normal' do test "rendered correctly" do assert_xpath "//p", render_string("Plain text for the win.\n\nYes, plainly."), 2 end test "with title" do rendered = render_string(".Titled\nParagraph.\n\nWinning") assert_...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/asciidoctor.gemspec
## This is the rakegem gemspec template. Make sure you read and understand ## all of the comments. Some sections require modification, and others can ## be deleted if you don't need them. Once you understand the contents of ## this file, feel free to delete any comments that begin with two hash marks. ## You can find c...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/abstract_node.rb
<gh_stars>0 module Asciidoctor # Public: An abstract base class that provides state and methods for managing a # node of AsciiDoc content. The state and methods on this class are comment to # all content segments in an AsciiDoc document. class AbstractNode include Substituters # Public: Get the element which is t...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/list_item.rb
<gh_stars>0 module Asciidoctor # Public: Methods for managing items for AsciiDoc olists, ulist, and dlists. class ListItem < AbstractBlock # Public: Get/Set the String used to mark this list item attr_accessor :marker # Public: Initialize an Asciidoctor::ListItem object. # # parent - The parent list block f...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/specifications/asciidoctor-0.1.0.gemspec
<filename>src/main/resources/ruby/1.9.1/specifications/asciidoctor-0.1.0.gemspec # -*- encoding: utf-8 -*- Gem::Specification.new do |s| s.name = "asciidoctor" s.version = "0.1.0" s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version= s.authors = ["<NAME>", "<N...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/reader_test.rb
<gh_stars>0 require 'test_helper' class ReaderTest < Test::Unit::TestCase # setup for test def setup @src_data = File.readlines(sample_doc_path(:asciidoc_index)) @reader = Asciidoctor::Reader.new @src_data end context "has_more_lines?" do test "returns false for empty document" do assert !As...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/substitutions_test.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin<gh_stars>0 require 'test_helper' # TODO # - test negatives # - test role on every quote type context 'Substitutions' do context 'Dispatcher' do test 'apply normal substitutions' do para = block_from_string("[blue]'http://asciidoc.org[AsciiDoc]' & [red]*Ruby*\n...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/inline.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin<filename>src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/inline.rb module Asciidoctor # Public: Methods for managing inline elements in AsciiDoc block class Inline < AbstractNode # Public: Get the text of this inline element attr_reader :text # ...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin<gh_stars>0 require 'rubygems' require 'strscan' $:.unshift(File.dirname(__FILE__)) #$:.unshift(File.join(File.dirname(__FILE__), '..', 'vendor')) # Public: Methods for parsing Asciidoc input files and rendering documents # using eRuby templates. # # Asciidoc documents co...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/attributes_test.rb
require 'test_helper' context 'Attributes' do context 'Assignment' do test 'creates an attribute' do doc = document_from_string(':frog: Tanglefoot') assert_equal 'Tanglefoot', doc.attributes['frog'] end test 'requires a space after colon following attribute name' do doc = document_from...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/test/preamble_test.rb
require 'test_helper' context 'Preamble' do test 'title and single paragraph preamble before section' do input = <<-EOS Title ===== Preamble paragraph 1. == First Section Section paragraph 1. EOS result = render_string(input) assert_xpath '//p', result, 2 assert_xpath '//*[@id="preamble"]', r...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/bundler/setup.rb
<reponame>wilkinsona/asciidoctor-gradle-plugin path = File.expand_path('..', __FILE__) $:.unshift File.expand_path("#{path}/../ruby/1.9.1/gems/asciidoctor-0.1.1/lib") $:.unshift File.expand_path("#{path}/../ruby/1.9.1/gems/coderay-1.0.8/lib") $:.unshift File.expand_path("#{path}/../ruby/1.9.1/bundler/gems/tilt-be401742...
wilkinsona/asciidoctor-gradle-plugin
src/main/resources/ruby/1.9.1/gems/asciidoctor-0.1.1/lib/asciidoctor/abstract_block.rb
module Asciidoctor class AbstractBlock < AbstractNode # Public: Get the Array of Asciidoctor::AbstractBlock sub-blocks for this block attr_reader :blocks # Public: Set the Integer level of this Section or the Section level in which this Block resides attr_accessor :level # Public: Set the String block title...
gleuch/display-mode
app.rb
require "rubygems" require "bundler" Bundler.setup require "sinatra" require "instagram" require "json" configure do APP_ENV = Sinatra::Application.environment.to_s APP_ROOT = File.expand_path(File.dirname(__FILE__)) end use Rack::Session::Cookie Instagram.configure do |config| oauth = YAML::load(File.open...
alexekim/mendel_inheritance
app.rb
<gh_stars>0 require 'bundler' #using ruby to require a gem Bundler.require # load all the gems in the gemfile class Peaplant #when def initialize(flower_color, *meta) # *meta is a splat @flower_color = flower_color @@seeds = true #all pea plants will have this @meta = meta end def to_s "A simpl...
HalcyonLA/HalcyonInnovationKit
HalcyonInnovationKit.podspec
Pod::Spec.new do |s| s.platform = :ios s.ios.deployment_target = '8.0' s.name = "HalcyonInnovationKit" s.module_name = "HalcyonInnovationKit" s.summary = "Halcyon Innovation development kit." s.requires_arc = true s.version = "1.3.35" s.author = { "<NAME>" => "<EMAIL>" } s.license = { :type => "MIT"...
pkucherenk0/peatio
spec/api/v2/admin/engines_spec.rb
# frozen_string_literal: true describe API::V2::Admin::Engines, type: :request do let(:admin) { create(:member, :admin, :level_3, email: '<EMAIL>', uid: 'ID73BF61C8H0') } let(:token) { jwt_for(admin) } let(:level_3_member) { create(:member, :level_3) } let(:level_3_member_token) { jwt_for(level_3_member) } ...
pkucherenk0/peatio
spec/api/v2/account/transactions_spec.rb
<reponame>pkucherenk0/peatio # encoding: UTF-8 # frozen_string_literal: true describe API::V2::Account::Transactions, type: :request do describe 'GET /api/v2/account/transactions' do let(:member) { create(:member, :level_3) } let(:token) { jwt_for(member) } let(:btc_account) { member.get_account('btc') }...
JRomeoSalazar/marcen
rakefile.rb
require 'coyote/rake' coyote :build do |config| config.input = "src/Sylius/Bundle/WebBundle/Resources/public/less/frontend.less" config.output = "src/Sylius/Bundle/WebBundle/Resources/public/css/frontend.css" end
JRomeoSalazar/marcen
template/rakefile.rb
<gh_stars>0 require 'coyote/rake' coyote :build do |config| config.input = "public/less/frontend.less" config.output = "public/css/frontend.css" end
GinBlades/stm_strategy
lib/generators/stm_strategy/install/templates/omniauth.rb
# Set the following values in secrets.yml: # auth_provider_url: # auth_provider_application_id: # auth_provider_secret: PROVIDER = Rails.application.secrets.auth_provider_url SETUP_PROC = lambda do |env| env['omniauth.strategy'].options[:client_id] = Rails.application.secrets.auth_provider_application_id env[...
GinBlades/stm_strategy
lib/omniauth/strategies/stm.rb
<reponame>GinBlades/stm_strategy<gh_stars>0 require 'omniauth-oauth2' module OmniAuth module Strategies class Stm < OmniAuth::Strategies::OAuth2 option :name, :stm uid { raw_info['id'] } info do { email: raw_info['email'], admin: raw_info['admin'] ...
GinBlades/stm_strategy
lib/stm_strategy.rb
require "stm_strategy/engine" require 'omniauth-oauth2' require 'omniauth/strategies/stm' module StmStrategy end
GinBlades/stm_strategy
app/controllers/stm_strategy/application_controller.rb
<filename>app/controllers/stm_strategy/application_controller.rb module StmStrategy class ApplicationController < ActionController::Base protect_from_forgery before_action :check_cookie def check_cookie if !cookie_valid? session[:user_id] = nil end end def cookie_valid? ...
GinBlades/stm_strategy
config/routes.rb
<filename>config/routes.rb Rails.application.routes.draw do # omniauth get '/auth/:provider/callback', :to => 'stm_strategy/user_sessions#create' get '/auth/failure', :to => 'stm_strategy/user_sessions#failure' # Custom logout post '/logout', :to => 'stm_strategy/user_sessions#destroy' end
EnisAdemov/WKJavaScriptController
WKJavaScriptController.podspec
<gh_stars>0 Pod::Spec.new do |s| s.name = 'WKJavaScriptController' s.version = '1.1.9' s.summary = 'Calling native code from Javascript in the iOS application likes JavascriptInterface in the Android.' s.homepage = 'https://github.com/EnisAdemov/WKJavaScriptController' s.authors = {...
ajroetker/puppet
lib/puppet/file_serving/metadata.rb
<filename>lib/puppet/file_serving/metadata.rb require 'puppet' require 'puppet/indirector' require 'puppet/file_serving' require 'puppet/file_serving/base' require 'puppet/util/checksums' # A class that handles retrieving file metadata. class Puppet::FileServing::Metadata < Puppet::FileServing::Base include Puppet:...
ajroetker/puppet
acceptance/tests/environment/enc_nonexistent_directory_environment.rb
<gh_stars>0 test_name "Master should produce error if enc specifies a nonexistent environment" testdir = create_tmpdir_for_user master, 'nonexistent_env' apply_manifest_on(master, <<-MANIFEST, :catch_failures => true) File { ensure => directory, owner => #{master.puppet['user']}, group => #{master.puppet['grou...
jreidinger/pull_requests_reminder
pr_reminder.rb
#! /usr/bin/env ruby require 'open-uri' require 'json' require 'ostruct' class GitHubAPI @@api_token_file = File.expand_path(File.dirname(__FILE__)) + "/api_token" @@api_token = nil def self.token if !@@api_token if ENV['GH_API_TOKEN'] @@api_token = ENV['GH_API_TOKEN'] elsif File.exists?...
vigo/textmate2-gfm-preview
Support/urlify.rb
require 'rubygems' require 'bundler/setup' Bundler.require LINK_REGEX_PATTERN = /^\[(.+)\]\(([a-z\-\.]+)\)$/ if ENV['TM_SELECTED_TEXT'] input = ENV['TM_SELECTED_TEXT'] input_has_patched = input.scan(LINK_REGEX_PATTERN) if input_has_patched.size > 0 text = input_has_patched.first.first link = input_ha...
vigo/textmate2-gfm-preview
Support/gfm.rb
require 'rubygems' require 'bundler/setup' Bundler.require require 'rouge/plugins/redcarpet' DELIMITER = /^---\s*$/ TIME_STAMP = Time.now.strftime('%s') CSS_FILES = ['github-markdown', 'syntax-hightlight'].map do |f| "<link rel=\"stylesheet\" href=\"file://#{ENV['TM_BUNDLE_SUPPORT']}/css/#{f}.css?#{TIME_STAMP}\">"...
fjlanasa/api
gem.deps.rb
source 'https://rubygems.org' gem 'pronto', '~> 0.7.1'
ioquatix/time-zone
lib/time/zone/locking.rb
# Copyright, 2018, by <NAME>. <http://www.codeotaku.com> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify...
ioquatix/time-zone
gems.rb
source "https://rubygems.org" # Specify your gem's dependencies in time-zone.gemspec gemspec
ioquatix/time-zone
time-zone.gemspec
<gh_stars>1-10 require_relative "lib/time/zone/version" Gem::Specification.new do |spec| spec.name = "time-zone" spec.version = Time::Zone::VERSION spec.authors = ["<NAME>"] spec.email = ["<EMAIL>"] spec.summary = "Computes timezones using the system TZ environment variable." spec.homepage = "https://github.c...
ioquatix/time-zone
lib/time/zone/timestamp.rb
# Copyright, 2018, by <NAME>. <http://www.codeotaku.com> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify...
ioquatix/time-zone
spec/time/zone_spec.rb
# Copyright, 2018, by <NAME>. <http://www.codeotaku.com> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify...
ioquatix/time-zone
spec/time/zone/timestamp_spec.rb
# Copyright, 2018, by <NAME>. <http://www.codeotaku.com> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify...
ioquatix/time-zone
spec/spec_helper.rb
<filename>spec/spec_helper.rb if ENV['COVERAGE'] || ENV['TRAVIS'] begin require 'simplecov' SimpleCov.start do add_filter "/spec/" end if ENV['TRAVIS'] require 'coveralls' Coveralls.wear! end rescue LoadError warn "Could not load simplecov: #{$!}" end end require "bundler/setup" require ...
ioquatix/time-zone
bug14879.rb
#!/usr/bin/env ruby # https://bugs.ruby-lang.org/issues/14879 require 'time' ENV['TZ'] = "Pacific/Auckland" time = Time.parse("5pm") ENV['TZ'] = "UTC" puts time puts time.utc_offset puts (time + 1).utc_offset puts time + 1
ioquatix/time-zone
lib/time/zone.rb
# Copyright, 2018, by <NAME>. <http://www.codeotaku.com> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify...
Calvin-Huang/omniauth-gitbook
spec/omniauth/strategies/gitbook_spec.rb
require 'spec_helper' describe OmniAuth::Strategies::GitBook do subject do OmniAuth::Strategies::GitBook.new({}) end context 'client options' do it 'should have correct site' do subject.options.client_options.site.should eq('https://api.gitbook.com') end it 'should have correct authorize...
Calvin-Huang/omniauth-gitbook
lib/omniauth/strategies/gitbook.rb
<reponame>Calvin-Huang/omniauth-gitbook<filename>lib/omniauth/strategies/gitbook.rb require 'omniauth-oauth2' module OmniAuth module Strategies class GitBook < OmniAuth::Strategies::OAuth2 base_url = 'https://api.gitbook.com' option :client_options, { site: base_url, authorize_ur...
Calvin-Huang/omniauth-gitbook
lib/omniauth-gitbook.rb
<filename>lib/omniauth-gitbook.rb<gh_stars>0 require 'gitbook/version' require 'omniauth/strategies/gitbook'
Calvin-Huang/omniauth-gitbook
spec/spec_helper.rb
<reponame>Calvin-Huang/omniauth-gitbook<filename>spec/spec_helper.rb require 'rspec' require 'rack/test' require 'webmock/rspec' require 'omniauth' require 'omniauth-gitbook' RSpec.configure do |config| config.include WebMock::API config.include Rack::Test::Methods config.extend OmniAuth::Test::StrategyMacros, t...
alelee93/yelp_api
lib/cli.rb
<filename>lib/cli.rb<gh_stars>0 class CLI def initialize @page = 1 @limit = 20 @@favorites = [] end def start introduction business_loop end def get_business_data(loc, query) puts "\n\n MAKING A NETWORK REQUEST ... \n\n" business_array = AP...
alelee93/yelp_api
lib/api_manager.rb
<reponame>alelee93/yelp_api<filename>lib/api_manager.rb class APIManager BASE_URL = "https://api.yelp.com/v3" def self.search_businesses(loc, query, pagenum=1, limit=20) business_search_url = BASE_URL + "/businesses/search" + "?limit=#{limit}&offset=#{(pagenum-1)*limit}" headers ...
alelee93/yelp_api
lib/response_strategy.rb
class ResponseStrategy def self.get_and_respond_to(prompt: , accepted_commands:, if_fail: ->(){ puts "That is an unknown command try again"},should_downcase: true, should_intergierize: false) loop do puts prompt user_input = gets.strip user_input = user_input.downcase i...
alelee93/yelp_api
lib/yelp_api.rb
require 'pry' require 'httparty' require_relative "./yelp_api/version" require_relative "./cli" require_relative "./api_manager" require_relative "./business" require_relative "./reviews" require_relative "./messages" ENV["runtime"] ||= "development" if ENV["runtime"] == "development" require_relative "../secrets"...
alelee93/yelp_api
lib/business.rb
class Business attr_accessor :categories, :coordinates, :display_phone, :distance, :id, :alias, :image_url, :is_closed, :location, :name, :phone, :price, :rating, :review_count, :url, :transactions @@all = [] def initialize(business_hash) @reviews = [] business_hash.each do |key, value| ...
alelee93/yelp_api
lib/messages.rb
class Messages def self.menu puts "What would you like to do today? Select a number from the menu below." sleep(1) puts <<-MENU ..........MENU.......... 1. New Yelp search 2. Browse Favorites list Type 'exit' to leave the program MENU end def self.intr...
alelee93/yelp_api
lib/yelp_api/version.rb
module YelpApi VERSION = "0.1.0" end
alelee93/yelp_api
lib/reviews.rb
<filename>lib/reviews.rb class Reviews attr_accessor :id, :text, :url, :rating, :time_created, :user @@all = [] def initialize(a_business = nil, review_hash) self.business=(a_business) if a_business != nil review_hash.each do |key, value| self.send("#{key}=", value) end ...
sunner/homebrew-cask
Casks/diskcatalogmaker.rb
cask "diskcatalogmaker" do version "8.3.1" sha256 :no_check url "https://download.diskcatalogmaker.com/zip/DiskCatalogMaker.zip" name "DiskCatalogMaker" desc "Toast-bundled version of DiskCatalogMaker" homepage "https://diskcatalogmaker.com/" livecheck do url "https://download.diskcatalogmaker.com/z...
sunner/homebrew-cask
Casks/heimatdefender-rebellion.rb
cask "heimatdefender-rebellion" do version :latest sha256 :no_check url "https://www.heimat-defender.de/download/11002/" name "Heimat Defender: Rebellion" desc "2D platformer game" homepage "https://www.heimat-defender.de/en/" app "HeimatDefender.app" zap trash: [ "~/Library/Application Support/c...
willrstern/mean-boilerplate
config/deploy/staging.rb
server 'staging.server.com', user: 'deploy', roles: %w{web} set :branch, ENV['branch'] || proc { `git rev-parse --abbrev-ref HEAD`.chomp } || 'master'
willrstern/mean-boilerplate
config/deploy.rb
lock '3.1.0' set :application, "my-application" set :repo_url, "<EMAIL>:youruser/#{fetch(:application)}.git" set :deploy_to, "~/#{fetch(:application)}" set :pty, true set :ssh_options, { keys: %w(provisioning/files/ssh/id_rsa), forward_agent: true, auth_methods: %w(publickey, password) ...
willrstern/mean-boilerplate
config/deploy/production.rb
<reponame>willrstern/mean-boilerplate server 'server.com', user: 'deploy', roles: %w{web}
Marketcircle/Specs
grabKit/1.3.1/grabKit.podspec
<reponame>Marketcircle/Specs Pod::Spec.new do |s| s.name = "grabKit" s.version = "1.3.1" s.summary = "Drop-in iOS component to easily import photos from Facebook, FlickR, Instagram, Picasa, and more." s.description = <<-DESC GrabKit allows you to retrieve photos from : * Facebook ...
Marketcircle/Specs
Chartbeat/0.0.1/Chartbeat.podspec
<filename>Chartbeat/0.0.1/Chartbeat.podspec Pod::Spec.new do |s| s.name = 'Chartbeat' s.version = '0.0.1' s.license = 'Commercial' s.summary = 'Chartbeat analytics library for iOS.' s.homepage = 'https://chartbeat.com/docs/ios/' s.author = { 'Chartbeat' => 'https...
Marketcircle/Specs
UniversalDetector/1.0.0/UniversalDetector.podspec
<reponame>Marketcircle/Specs Pod::Spec.new do |s| s.name = 'UniversalDetector' s.version = '1.0.0' s.license = { :type => 'Mozilla Public License', :file => 'LICENSE' } s.summary = 'Wrapper of uchardet for Objective-C.' s.description = 'Universal...
Marketcircle/Specs
QR-Code-Encoder-for-Objective-C/1.0.0/QR-Code-Encoder-for-Objective-C.podspec
Pod::Spec.new do |spec| spec.name = 'QR-Code-Encoder-for-Objective-C' spec.platform = :ios spec.version = '1.0.0' spec.license = 'Apache2.0' spec.summary = 'An implementation of QR code encoder for Objective-C ported from Psytec library.' spec.homepage = 'https://g...
Marketcircle/Specs
STTwitter/0.0.1/STTwitter.podspec
<gh_stars>1-10 # # Be sure to run `pod spec lint STTwitter.podspec' to ensure this is a # valid spec and remove all comments before submitting the spec. # # To learn more about the attributes see http://docs.cocoapods.org/specification.html # Pod::Spec.new do |s| s.name = "STTwitter" s.version = "0.0....
Marketcircle/Specs
iOS-GTLYouTube/0.0.3/iOS-GTLYouTube.podspec
<reponame>Marketcircle/Specs<filename>iOS-GTLYouTube/0.0.3/iOS-GTLYouTube.podspec # # iOS-GTLYouTube # CocoaPods podspec # Pod::Spec.new do |s| s.platform = :ios, '5.1' s.name = 'iOS-GTLYouTube' s.version = '0.0.3' s.author = { '<NAME>' => '<EMAIL>' } s.summary = 'Auto-generated G...
Marketcircle/Specs
DHCCounter/0.0.1/DHCCounter.podspec
<reponame>Marketcircle/Specs # # Be sure to run `pod spec lint DHCCounter.podspec' to ensure this is a # valid spec and remove all comments before submitting the spec. # # To learn more about the attributes see http://docs.cocoapods.org/specification.html # Pod::Spec.new do |s| s.name = "DHCCounter" s.versi...
Marketcircle/Specs
KASlideShow/1.0/KASlideShow.podspec
Pod::Spec.new do |s| s.name = 'KASlideShow' s.version = '1.0' s.platform = :ios s.license = {:type =>'Apache V2.0', :file =>'LICENSE'} s.summary = 'Minimal slideshow for iOS. Support manual or automatic slideshow, with fade and slide transitions.' s.homepage = 'http://alexiscreuzot.com/KASlideShow' ...
Marketcircle/Specs
NNNetwork/0.0.1/NNNetwork.podspec
<filename>NNNetwork/0.0.1/NNNetwork.podspec # Specfile for NNNetwork Pod::Spec.new do |s| s.name = "NNNetwork" s.version = "0.0.1" s.summary = "Networking categories, OAuth and read later clients." s.description = <<-DESC `NNNetwork` is a collection of classes that power networking in Postr. ...
Marketcircle/Specs
KANibHelper/0.4/KANibHelper.podspec
Pod::Spec.new do |s| s.name = 'KANibHelper' s.version = '0.4' s.platform = :ios s.license = {:type =>'Apache V2.0', :file =>'LICENSE'} s.summary = 'When you need to have two very distinct interfaces between 3.5 and 4 inches screens.' s.homepage = 'http://alexiscreuzot.com/KANibHelper' s.author = ...
Marketcircle/Specs
UICustomizeKit/0.0.1/UICustomizeKit.podspec
<filename>UICustomizeKit/0.0.1/UICustomizeKit.podspec Pod::Spec.new do |s| s.name = "UICustomizeKit" s.version = "0.0.1" s.summary = "The UICustomizeKit extends standard UIKit components to make amazing looking controls." s.homepage = "https://github.com/daltoniam/UICustomizeKit" s.licen...
Marketcircle/Specs
TICoreDataSync/1.0.2/TICoreDataSync.podspec
<gh_stars>1-10 Pod::Spec.new do |s| s.name = "TICoreDataSync" s.version = "1.0.2" s.summary = "Automatic synchronization for Core Data Apps, between any combination of Mac OS X and iOS." s.homepage = "http://nothirst.github.com/TICoreDataSync" s.license = { :type => 'MIT', :text => <...
Marketcircle/Specs
PlaynomicsSDK/8/PlaynomicsSDK.podspec
<reponame>Marketcircle/Specs Pod::Spec.new do |s| s.name = 'PlaynomicsSDK' s.version = '8' s.license = { :type => 'Commercial', :text => 'See http://www.playnomics.com/platformpolicy/' } s.summary = 'Playnomics PlayRM iOS SDK.' s.homepage = 'http://www.playnomics.com' s.author = { 'Playnomics' => '<EMAIL>' ...
Marketcircle/Specs
nv-ios-http-status/0.0.1/nv-ios-http-status.podspec
# # Be sure to run `pod spec lint nv-ios-http-status.podspec' to ensure this is a # valid spec and remove all comments before submitting the spec. # # To learn more about the attributes see http://docs.cocoapods.org/specification.html # Pod::Spec.new do |s| s.name = "nv-ios-http-status" s.version = "0....
Marketcircle/Specs
SqliteFTS/0.0.1/SqliteFTS.podspec
<gh_stars>0 Pod::Spec.new do |s| s.name = "SqliteFTS" s.version = "0.0.1" s.summary = "SQLiteFTS is a static library providing a rebuild SQLite database from source code to add FTS support." s.description = <<-DESC ## What's this project for? This project rebuild the SQLite database from sour...
Marketcircle/Specs
NRGramKit/1.0/NRGramKit.podspec
# # Be sure to run `pod spec lint NRGramKit.podspec' to ensure this is a # valid spec and remove all comments before submitting the spec. # # To learn more about the attributes see http://docs.cocoapods.org/specification.html # Pod::Spec.new do |s| s.name = "NRGramKit" s.version = "1.0" s.summary ...
Marketcircle/Specs
flojack-ios/0.0.1/flojack-ios.podspec
<gh_stars>1-10 Pod::Spec.new do |s| s.name = "flojack-ios" s.version = "0.0.1" s.summary = "iOS static lib for FloJack NFC reader/writer." s.homepage = "https://github.com/flomio/flojack-ios" s.license = 'Apache v2' s.author = { "<NAME>" => "<EMAIL>", "<NAME>" => "<EMA...
Marketcircle/Specs
MRCEnumerable/0.1.1/MRCEnumerable.podspec
<gh_stars>1-10 # # Be sure to run `pod spec lint MRCEnumerable.podspec' to ensure this is a # valid spec and remove all comments before submitting the spec. # Pod::Spec.new do |s| s.name = "MRCEnumerable" s.version = "0.1.1" s.summary = "Collection of Ruby Enumerable style methods on common coll...
Marketcircle/Specs
GoogleConversionTracking/1.2.0/GoogleConversionTracking.podspec
Pod::Spec.new do |s| s.name = 'GoogleConversionTracking' s.version = '1.2.0' s.summary = 'Google Conversion Tracking SDK for iOS.' s.description = 'If you\'d like to know which of your keywords best leads to clicks and conversions, such as sales, AdWords Conversion Tracking can help you.' s.homepage = 'https:...