This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=begin | |
絶対に使用してはいけません(後述)。 | |
ファイルのタイムスタンプが 2010/12/31 のふぁぼ爆対策プラグインがでてきたので、記録目的で公開します。 | |
== 仕様 | |
ふぁぼられた相手ごとにふぁぼ数をカウントし、3ふぁぼ以上されると、それ以降ふぁぼられる毎に相手に | |
いい加減にしろとリプライを送ります。 | |
ふぁぼカウントは、ふぁぼが3分途切れたらリセットされます。 | |
== mikutter 3.0で動かした場合の不具合 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
Plugin.create(:mikutter_iconbyebye) do | |
ALTERNATIVE_IMAGE = "http://pbs.twimg.com/profile_images/434359790551068673/JTrPZYsz_normal.png".freeze | |
filter_show_filter do |messages| | |
replaced = messages.map do |message| | |
if UserConfig[:iconbyebye_sn].include? message.user[:idname] | |
message[:user] = Message::MessageUser.new(message.user, profile_image_url: ALTERNATIVE_IMAGE) | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# あっきぃの最近のツイートが見えない不具合の次善策です。 | |
# 現象: https://dev.twitter.com/discussions/25939 | |
# 祭会場: http://togetter.com/li/629097 | |
Plugin.create(:avoid_25939) do | |
profiletab :avoid_25939, "avoid 25939" do | |
set_icon Skin.get("search.png") | |
uid = user.id | |
i_timeline = timeline nil do | |
order do |message| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
require "webkit-gtk2" | |
Plugin.create(:kancolle) do | |
tab(:kancolle, "艦これ") do | |
view = WebKitGtk2::WebView.new | |
view.load_uri("http://www.dmm.com/netgame/feature/kancolle.html") | |
nativewidget view.show_all | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/ruby | |
# -*- coding: utf-8 -*- | |
# how to use | |
# (in minecraft directory) | |
# $ ./basicmod_installer.rb /path/to/minecraft-forge.zip [/path/to/another/mods ...] | |
require "fileutils" | |
MC_ROOT = File.expand_path(File.dirname(__FILE__)) | |
JAR_NAME = "minecraft.jar" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.DS_Store | |
/screenshots/ | |
/texturepacks-mp-cache/ | |
/lastlogin | |
*.log | |
/saves/MOD Test | |
*(navel * | |
/crash-reports/ | |
/IDChecker/ | |
/stats/stats_toshi_a_unsent.dat |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UserConfig[]の戻り値は、freezeされてるから、この戻り値自体に破壊的な変更はできない。 | |
UserConfig[:test] << :value # => なんかエラー | |
freezeされているオブジェクトは、mikutterではmeltで変更可能になるが、その時内部的にはシャローコピーされてしまうので、UserConfig自体には変更できない | |
UserConfig[:test].melt << :value # => [:value] | |
# result | |
UserConfig[:test] # => [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Plugin.create :twihai_achievements do | |
defachievement(:red_fav, | |
description: "1つのツイートに5ふぁぼ以上された", | |
hint: "おもしろツイートで5fav以上もらおう" | |
) do |achievement| | |
on_favorite do |service, user, message| | |
if message.user.is_me? and message.favorited_by.size >= 5 | |
achievement.take! end end end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Plugin.create :spellchecker do | |
filter_gui_timeline_selected_messages do |timeline, messages| | |
messages.each { |message| | |
raise RuntimeError if /[Ff]ile:\/\/\// =~ message.to_s | |
} | |
[timeline, messages] | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Plugin.create :laco do | |
command(:laco, | |
name: 'らこらこらこ〜', | |
condition: lambda{ |opt| true }, | |
visible: true, | |
role: :timeline) do |opt| | |
Service.primary.update(message: "らこらこらこ〜") | |
end | |
end |