Skip to content

Instantly share code, notes, and snippets.

require 'find'
class Watchlog
class LogFile
def initialize(path)
@path = path
@pid = nil
@wth = nil
end
APIパス システム名 サブシステム名 コンポーネント名 ファイル名
/api01r/acceptlst 日医標準レセプトソフト API連携用モジュール 受付一覧 ORAPI011R1
/api01r/appointlst 日医標準レセプトソフト API連携用モジュール 予約一覧 ORAPI014R1
/api01r/diseaseget 日医標準レセプトソフト API連携用モジュール 患者病名返却 ORAPI022R1
/api01r/medicalget 日医標準レセプトソフト API連携用モジュール 診療行為返却1 ORAPI021R1
/api01r/patientget 日医標準レセプトソフト API連携用モジュール 患者基本情報取得 ORAPI012R1
/api01r/patientlst1 日医標準レセプトソフト API連携用モジュール 患者番号一覧取得処理 [ORAPI012R2](https://github.com/orcacvsmirror/jma-receipt/blob/master/cobol/a
# -*- mode: ruby -*-
Vagrant.configure(2) do |config|
config.vm.box = 'ubuntu/xenial64'
config.vm.network 'forwarded_port', guest: 5432, host: 15432
config.vm.network 'forwarded_port', guest: 8000, host: 18000
config.vm.provider 'virtualbox' do |vb|
vb.cpus = 4
vb.memory = 4094
end
require 'web_push'
# Generate a keys and puts it to Rails.application.secrets.web_push_public_key
pkey = WebPush::Utils.generate_vapid_pkey
# Rails.application.secrets.web_push_private_key
vapid_private_key = Base64.urlsafe_encode64(pkey.private_key.to_bn.to_s(2)).delete('=')
puts "vapid_private_key = #{vapid_private_key}"
# Rails.application.secrets.web_push_public_key
require 'restclient'
require 'json'
namespace :sentry do
class SentryReleaseAPI
def initialize(organization_slug: nil, project_slug: nil, api_key: nil)
@organization_slug = organization_slug || ENV['SENTRY_ORGANIZATION_SLUG']
@project_slug = project_slug || ENV['SENTRY_PROJECT_SLUG']
@api_key = api_key || ENV['SENTRY_API_KEY']
end
const actionCreator = () => ({ type: 'SOME_ACTION' });
const noopReducer = (state, action) => state;
const noopEnhancer = (store) => store;
const noopMiddleware = store => next => action => next(action);
export function createStore(reducer = noopReducer, initialState = undefined, enhancer = noopEnhancer) {
let state = initialState;
let listeners = [];
const dispatch = (action) => {
require 'active_support/core_ext/string/inflections'
require 'active_support/core_ext/hash/indifferent_access'
module Snaky
refine Hash do
def to_snake_case(value = self)
case value
when Hash
value.map { |k, v| [k.underscore, to_snake_case(v)] }.to_h.with_indifferent_access
when Array
@miyucy
miyucy / quwk.rb
Created May 25, 2016 17:09
Queue Worker
require 'thread'
class QuWk
NUM = 3
def initialize
@queue = Queue.new
@workers = []
@num = NUM
@block = proc {}
source 'https://rubygems.org'
gem 'rails', '~> 4.2.0'
gem 'pry-byebug'
@miyucy
miyucy / listup.rb
Created December 22, 2015 08:31
detect heavy assets
begin
class Capybara::Poltergeist::NetworkTraffic::Response
def stage
@data['stage']
end
end
poltergeist_drivers = Capybara
.send(:session_pool)
.each_value.map(&:driver)