This file contains 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 'fileutils' | |
require 'tempfile' | |
# cn = '*.tb.local.vhost' | |
# server_name = 'dev.tb.local.vhost' | |
# admin_server_name = 'admin.tb.local.vhost' | |
This file contains 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
#include <iostream> | |
#include <string> | |
#include <iomanip> | |
using namespace std; | |
int m; //Total number of rows | |
int n; //Total number columns | |
double w; //The size of each tile in inches | |
double h; //The size of each tile in inches |
This file contains 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
3.1 |
This file contains 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 'uri' | |
require 'json' | |
require 'net/http' | |
class Gql | |
class Base | |
Response = Struct.new(:http) do | |
def success? | |
http.is_a?(Net::HTTPSuccess) |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
# Choose a version of Ruby | |
FROM ruby:2.7.3-slim | |
ARG APP_NAME=lentille | |
ARG BUNDLER_ARGS | |
ARG BUNDLE_WITH | |
ARG BUNDLE_WITHOUT | |
ARG BUNDLE_DEPLOYMENT | |
ENV APP_NAME=${APP_NAME} |
This file contains 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 | |
# frozen_string_literal: true | |
require 'json' | |
require 'pry' | |
def files | |
@files ||= begin | |
`git diff --staged --name-only --cached`.split("\n").reject do |file| | |
!File.exists?(file) | |
end |
This file contains 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 | |
class ExampleStatusParser | |
def self.parse(string) | |
new(string).parse | |
end | |
def initialize(string) | |
@header_line, _, *@row_lines = string.lines.to_a | |
end |
This file contains 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 'net/http' | |
require 'open-uri' | |
require 'tempfile' | |
require File.expand_path('ruby_bash', __dir__).to_s | |
options = {} | |
parser = OptionParser.new do |opts| | |
opts.banner = 'Usage: replicate gem inabox' |