Skip to content

Instantly share code, notes, and snippets.

View fukuiretu's full-sized avatar
:octocat:
Working from home

Retu Fukui fukuiretu

:octocat:
Working from home
View GitHub Profile
@fukuiretu
fukuiretu / thread_safe_exmple.rb
Last active February 29, 2016 08:58
parallelのスレッドセーフtest
require 'parallel'
class Dummy
def initialize
@cnt = 0
end
def increment
@cnt += 1
end
@fukuiretu
fukuiretu / gist:581d28024e57645efab542d67311cf29
Created June 13, 2016 12:25 — forked from yomotsu/gist:00d7475651a5ed556c3f
monokai のコードハイライトで keynote にペーストしたい

python のパッケージ Pygments をインストール。

$ sudo easy_install Pygments
pygmentize -f rtf -O 'fontface=Monaco,style=monokai' path/to/file.html | pbcopy
@fukuiretu
fukuiretu / index.d.ts
Last active November 27, 2021 15:57
Nuxt.jsで必要なTypeScriptの型定義
import Vue from 'vue'
import { Route } from 'vue-router'
import { Store } from 'vuex'
import { MetaInfo } from 'vue-meta'
import { AxiosInstance } from 'axios'
interface NuxtContext {
isClient: boolean
isServer: boolean
isStatic: boolean
@fukuiretu
fukuiretu / workflow.yaml
Created October 24, 2019 11:27
github-actions-golang-test
on: [push]
name: Test
jobs:
test:
strategy:
matrix:
go-version: [1.13.x]
platform: [ubuntu-latest]
runs-on: ${{ matrix.platform }}
steps:
@fukuiretu
fukuiretu / ChatGPT.js
Created March 4, 2023 04:56 — forked from kmizu/ChatGPT.js
Google Apps Script to use ChatGPT API
function doPost(e) {
// slack appsのEvent Subscriptionsのchallenge。同期する時に利用。
var params = JSON.parse(e.postData.getDataAsString());
if('challenge' in params)
{
return ContentService.createTextOutput(params.challenge);
}
// ユーザ名とtextを取得
var userName = params.event.user;