Skip to content

Instantly share code, notes, and snippets.

View exoego's full-sized avatar
🏠
Working from home

TATSUNO “Taz” Yasuhiro exoego

🏠
Working from home
View GitHub Profile
@j5ik2o
j5ik2o / gist:1520836
Last active January 3, 2017 17:09
Scalaで使えそうなWeb系フレームワーク&ライブラリ
@vasanthk
vasanthk / System Design.md
Last active May 16, 2024 20:21
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@Frozenfire92
Frozenfire92 / gist:3627e38dc47ca581d6d024c14c1cf4a9
Last active October 20, 2021 20:58
Install Scala and SBT using apt-get on Ubuntu 16.04 or any Debian derivative using apt-get
## Java
sudo apt-get update
sudo apt-get install default-jdk
## Scala
sudo apt-get remove scala-library scala
sudo wget http://scala-lang.org/files/archive/scala-2.12.1.deb
sudo dpkg -i scala-2.12.1.deb
sudo apt-get update
sudo apt-get install scala
@ochrons
ochrons / WorkerMain.scala
Created May 25, 2016 19:59
Web Worker PoC in Scala.js
package poc
import org.scalajs.dom
import scala.scalajs.js
import scala.scalajs.js.annotation.JSExport
@js.native
object WorkerGlobal extends js.GlobalScope {
def addEventListener(`type`: String, f: js.Function): Unit = js.native
@eiel
eiel / chatwork-api-swagger.yaml
Last active January 27, 2021 10:06
ChatWork APIのSwagger
swagger: '2.0'
info:
title: ChatWork API
version: v1
# the domain of the service
host: api.chatwork.com
# array of all schemes that your API supports
schemes:
- https
# will be prefixed to all paths
@twolfson
twolfson / README.md
Created September 14, 2017 00:42
Handling uncaught sync and async errors in AWS Lambda

AWS Lambda has nice safeguards for logging but not great handling for error reporting. I typically use Sentry but in this project, we're using Rollbar

Here's a setup to remove AWS Lambda's forceful exit on uncaught error and replace it with an error reporter to Rollbar:

// Load in our dependencies
const assert = require('assert');
const Rollbar = require('rollbar');

// Initialize our Rollbar handler
@ProGM
ProGM / arel_cheatsheet_on_steroids.md
Last active May 15, 2024 20:55
Arel cheatsheet on Steroids

Arel Cheatsheet on Steroids

A (more) complete cheatsheet for Arel, including NamedFunction functions, raw SQL and window functions.

Tables

posts = Arel::Table.new(:posts)
posts = Post.arel_table # ActiveRecord

Table alias

// ==UserScript==
// @name gh - show approvals
// @namespace https://github.com/unarist
// @version 0.3
// @author unarist
// @match https://github.com/*
// @grant none
// @downloadURL https://gist.github.com/unarist/c45bd5e8102afe7ce27d757a87819ea4/raw/github-show-approvals.user.js
// @run-at document-idle
// @noframes
import scalafix.Diagnostic
import scalafix.Patch
import scalafix.lint.LintSeverity
import scalafix.v1.SyntacticDocument
import scalafix.v1.SyntacticRule
import scala.meta.Lit
import scala.meta.Term
import scala.meta.inputs.Position
class NoElse extends SyntacticRule("NoElse") {
rules = [
Disable
DisableSyntax
ExplicitResultTypes
LeakingImplicitClassVal
NoAutoTupling
NoValInForComprehension
ProcedureSyntax
RemoveUnused
MissingFinal