Skip to content

Instantly share code, notes, and snippets.

View kawahara's full-sized avatar

Shogo Kawahara (bucyou) kawahara

  • freee
  • Kyoto, Japan
  • 00:11 (UTC +09:00)
View GitHub Profile
@kawahara
kawahara / openapi.cue
Last active August 22, 2023 12:18
The cue definitions for openapi (3.0.3)
package definition
#openapi: {
openapi: "3.0.3"
info: #info
servers?: [...#server]
paths: #paths
components?: #components
security?: [...#security_requirement]
tags?: [...#tag]
const ArgumentType = require('../../extension-support/argument-type');
const BlockType = require('../../extension-support/block-type');
class MineCraft {
constructor () {
this.endpoint = 'http://localhost:8080/api/v5'
this.apiKey = null
this.worlds = []
this.players = []
this.player = null
(function(ext) {
ext._shutdown = function() {};
ext._getStatus = function() {
return {status: 2, msg: 'Ready'};
};
ext.get_weather = function(callback) {
$.ajax({
url: 'http://api.openweathermap.org/data/2.5/weather?q=Kashiwa,%20JP&units=imperial&APPID=fa4bc3cd05fcedff03fcec2db6bb2a4f',
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
</head>
<body>
<form id="search-form">
<input id="keyword" name="keyword" value="" required>
<input type="submit" value="検索">
</form>
@kawahara
kawahara / Gemfile
Last active December 22, 2015 23:39
source 'https://rubygems.org'
gem 'httpclient'
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js"></script>
</head>
<body>
<script>
$.ajax({
// ==UserScript==
// @name GitHub Compare Button
// @namespace http://tampermonkey.net/
// @version 0.1
// @description This script can add compare button to GitHub commit log.
// @author Shogo Kawahara <kawahara@bucyou.net>
// @match https://github.com/*
// @grant none
// ==/UserScript==
/* jshint -W097 */
@kawahara
kawahara / sample_code.html
Created October 17, 2012 11:18
sample_code
<!DOCTYPE>
<!--
It's a sample code for RWS by jQuery
-
Copyright (c) 2012 Shogo Kawahara
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
@kawahara
kawahara / data
Created September 14, 2012 17:25
test datas
data1
<?php
// autoload.php を読み込む
require_once __DIR__.'/autoload.php';
$client = new RakutenRws_Client();
$client->setApplicationId('アプリID');
$response = $client->execute('IchibaItemSearch', array(
// アフィエイトIDをパラメータにセット