Skip to content

Instantly share code, notes, and snippets.

View sifue's full-sized avatar

Soichiro Yoshimura sifue

View GitHub Profile
@shyouhei
shyouhei / gist:266178ffedab5767a5b69b972c76f88a
Created September 27, 2017 07:31
優秀なプログラマーになるためのコツ

優秀なプログラマーになるためのコツ

重要な順で

優秀なプログラマーになるには非常に長い時間がかかるという現実を直視すべし

優秀なプログラマーというのは寝ている間に異世界に召喚されて無双するのとはわけが違うんですよ。

自分の例で言うとプログラミングを始めた中学生の時から優秀なプログラマだったかって、そんなわけない。みんなヘッポコからスタートしているに決まってるわけです。以来二十余年、地道に生き恥を晒し続けてきた結果として、現在いちおう業界の末席を汚すところまで来ている。このプロセスから目を背けるべきではないです。優秀なプログラマーに生まれる人間なんかいない。優秀なプログラマーに「育つ」んだし、それには時間が必要。今日から無双したいと思うな。

@mikebridge
mikebridge / exampleComponent.tsx
Created April 28, 2017 20:33
An example react component in TypeScript
import * as React from "react";
import * as PropTypes from "prop-types";
interface IExampleComponentProps {
text?: string;
onCounterIncrease: (count: number) => void;
}
interface IExampleComponentState {
clicks: number;

共変・反変があるとどう嬉しいのか考えるコーナー

考える際の土台として、以下のようなクラスを考えます。

class Person(val name: String)
class Teacher(override val name: String, val kamoku: String) extends Person(name)

また 文字列からクラスAのインスタンスを生成する Read[A] とクラスAのインスタンスから文字列を生成する Write[A] というクラスについて考えてみます。(ReadはfromJson、WriteはtoJsonのようなイメージです。)

@timotgl
timotgl / uninstall-razer-synapse.sh
Last active April 24, 2024 15:20
How to fully uninstall Razer Synapse 2 on OS X (10.11-10.13) (El Capitan, Sierra, High Sierra) without using Razer's official uninstall tool
# How to uninstall Razer Synapse 2 ( https://www.razerzone.com/synapse-2 )
# on OS X (10.11-10.13) (El Capitan, Sierra, High Sierra)
# without using Razer's official uninstall tool.
# Tested on OS X 10.11.5 in July 2016.
# Edited with additional steps for later OS X versions,
# contributed by commenters on this gist.
# Step 1: In your terminal: stop and remove launch agents
launchctl remove com.razer.rzupdater
@xuwei-k
xuwei-k / gist:f5dbc6f55ee53de84ded
Last active August 29, 2015 14:07
playが、なぜnettyからakka-streamにしたいのか?という理由や、モニタリングの話
Hello again,
Thanks again guys for hosting the meetup, it was really great :-)
I promised to get back with some information I wanted to confirm with the team, but in general for example the netty/akka-io question is answered as I hinted at during the meetup:
Please note that these roadmaps are subject to change, as some of the points reach out more than a year ahead,
nevertheless I wanted to let you know of our current plans:
Will play be moving away from netty?
Not in 2.x, there will be both implementations available - akka-streams and netty.
In 3 netty will *most probably*
@udzura
udzura / tutorial.md
Created June 2, 2014 03:31
Hubot + CoffeeScript ではじめるやわらかプログラミング入門

やわらかプログラミング入門

  • Hubot であそぼう


始めに、地図を描く

@gakuzzzz
gakuzzzz / 1_.md
Last active August 2, 2023 01:59
Scala の省略ルール早覚え

Scala の省略ルール早覚え

このルールさえ押さえておけば、読んでいるコードが省略記法を使っていてもほぼ読めるようになります。

メソッド定義

def concatAsString(a: Int, b: Int): String = {
  val a_ = a.toString();
  val b_ = b.toString();
@miyamae
miyamae / gist:5664554
Last active December 17, 2015 19:59
Rails4でwheneverのrunnerジョブを定義する方法

Rails4だとscript/runnerがないので、今のところ(2013/5時点)wheneverのrunnerジョブが使えない。

そこで次のような感じで独自のjob_typeを定義すればok。

job_type :rails4_runner, "cd :path && bin/rails runner -e :environment :task.execute :output"

every 1.day, at: '01:00' do
  rails4_runner 'Tasks::HogeTask'
end
@j5ik2o
j5ik2o / hoge.md
Last active December 17, 2015 12:29
play idea -> IDEAでビルドすると以下のエラー。

playからIDEAプロジェクトを生成する

$ play idea

IDEAでビルドする

scala: Output path ???-api/project/target/scala_2.9.2 is shared between: Module '???-domain-build' production, Module '???-infrastructure-build' production, Module '???-api-build' production, Module '???-domain-build' tests, Module '???-infrastructure-build' tests, Module '???-api-build' tests
Currently external Scala compiler prohibits output path sharing.
Either disable the external build mode or configure separate output paths.
@japboy
japboy / jade-ftw.md
Last active October 23, 2023 11:18
Jade について。

Jade FTW

こんにちは。今回は現実逃避を兼ねて Jade の素晴らしさをお伝えしたいと思います。

Jade とは何か

[Jade][0] は JST (JavaScript Templates) の一つであり、HTML を書くための[軽量マークアップ言語][1] である [Haml][2] に影響を受けた JavaScript テンプレートエンジンでもあります。