参考: http://cuto.unirita.co.jp/gostudy/post/go-package/
/Users/vkgtaro/hoge
├─ main.go
└─ src
└─ model
├─ model.go <= import "model"
└─ user
└─ user.go <= import "model/user"
| /** | |
| * お知らせシートの messages シートから、お知らせを生成して chatwork に投稿する | |
| */ | |
| var Notifier = function () { | |
| this.config_sheet_name = 'configuration'; | |
| this.messages_sheet_name = 'messages'; | |
| this.rooms_sheet_name = 'rooms'; | |
| this.default_delivery_hour = 10; | |
| this.default_delivery_minute = 0; |
参考: http://cuto.unirita.co.jp/gostudy/post/go-package/
/Users/vkgtaro/hoge
├─ main.go
└─ src
└─ model
├─ model.go <= import "model"
└─ user
└─ user.go <= import "model/user"
| // ==UserScript== | |
| // @name 3gokushi-TroopTool | |
| // @namespace https://gist.github.com/vkgtaro/ee208f548590b66019ca1beb3e896a72 | |
| // @description ブラウザ三国志 出兵ツール | |
| // @include http://*.3gokushi.jp/* | |
| // @exclude http://info.3gokushi.jp/* | |
| // @version 1.4 | |
| // @require http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js | |
| // @require http://ajax.microsoft.com/ajax/jquery.templates/beta1/jquery.tmpl.js |
| // Amazonの注文履歴をTSV形式で出力するスクリプト | |
| // | |
| // 2015-01-01 時点での DOM 構造に対応, GoogleCrome, Opera でテスト済。 | |
| // formatEntry関数を書き換えれば自由な書式で出力できます。 | |
| // 金額取って出すように変更しました | |
| // | |
| // 参考: | |
| // - Amazonの注文履歴をCSV形式にして出力するスクリプト | |
| // https://gist.github.com/arcatdmz/8500521 | |
| // - Amazon で使った金額の合計を出す奴 (2014 年バージョン) |
| --- a/subversion/libsvn_subr/path.c | |
| +++ b/subversion/libsvn_subr/path.c | |
| @@ -40,6 +40,9 @@ | |
| #include "dirent_uri.h" | |
| +#if defined(DARWIN) | |
| +#include <CoreFoundation/CoreFoundation.h> | |
| +#endif /* DARWIN */ | |
| --- subversion/libsvn_subr/path.c 2015-08-12 13:59:32.000000000 +0900 | |
| +++ subversion/libsvn_subr/path.c.new 2015-08-12 13:59:16.000000000 +0900 | |
| @@ -40,6 +40,9 @@ | |
| #include "dirent_uri.h" | |
| +#if defined(DARWIN) | |
| +#include <CoreFoundation/CoreFoundation.h> | |
| +#endif /* DARWIN */ | |
| calculate_cosine = function (x, y) { return x / Math.sqrt(x*x + y*y); }; | |
| calculate_radian = function (cos) { return Math.acos(cos) / (Math.PI / 180); }; |
| this.sprite = new cc.Sprite("/path/to/card.png"); | |
| this.sprite.attr({ | |
| x: size.width / 2, | |
| y: size.height / 2 | |
| }); | |
| this.addChild(this.sprite, 0); | |
| orbit = cc.orbitCamera(1.5, 1, 0, 0, 360, 0, 0); | |
| this.sprite.runAction(orbit.repeatForever()); |
| var animation = cc.AnimationCache.getInstance().getAnimation('animation_name'); | |
| animation.setRestoreOriginalFrame(true); | |
| var animation_sprite = cc.Sprite.create( image_path, cc.rect(0, 0, width, height) ); | |
| animation_sprite.setPosition(220, 240); | |
| layer.addChild(anime_sprite, 300); | |
| animation_sprite.runAction( cc.RepeatForever.create( cc.Animate.create(animation)) ); | |
| animation_sprite.runAction( cc.MoveBy.create(10, cc.p(200,100) ) ); |
| var animationLoad = function (animation_name, width, height, turn_point, count, delay_time, image_path) { | |
| var x_count = 0; | |
| var y_count = 0; | |
| var frames_array = []; | |
| for (var i = 0; i < count; i++ ) { | |
| var current_x = width * x_count; | |
| var current_y = height * y_count; | |
| var frame = cc.SpriteFrame.create( | |
| image_path, |