表示の操作
- Command + 1: ★
- Command + 2: 未読
- Command + 3: すべて
アイテム/フォルダの移動
- K: 前のフィード
- J: 後のフィード
- Shift+K: ブラウザのまま前のフィード
- Shift+J: ブラウザのまま次のフィード
- Shift+P: 前のフォルダへ移動
- Shift+N: 次のフォルダへ移動
test_warn();
sub test_warn {
warn 'warn_message';
}
# warn_message at exception.pl line 13.
test_die();
sub test_die {
die 'die_message';
}
# die_message at exception.pl line 18.
use Carp;
test_carp();
sub test_carp {
carp 'carp_message';
}
#carp_message at exception.pl line 23
# main::test_carp() called at exception.pl line 21
use Carp;
test_croak();
sub test_croak {
croak 'croak_message';
}
# croak_message at exception.pl line 28
# main::test_croak() called at exception.pl line 26
踏み台サーバ : ssh_host01
社内プロキシサーバ: proxy_host01:8080
メールサーバ : mail_pop_01:110
送信サーバ : mail_smtp_01:25
IRC : irc_host_01:6778
webサーバ localhost:8080 => proxy_host01:8080 に接続
メールサーバ localhost:60110 => mail_pop_01:110 に接続
送信サーバ localhost:60025 => mail_smtp_01:25 に接続
IRC localhost:60001 => irc_host_01:6778 に接続
ssh ssh_host01 ¥
-L 8080:proxy_host01:8080 ¥
-L 60110:mail_pop_01:110 ¥
-L 60025:mail_smtp_01:25 ¥
-L 60001:irc_host_01:6778
| 'control' + 'u' | セルの編集 |
| 'option' + '→' 'option' + '-' | シート切り替え |
| 'control' + 'shift' + '+' 'control' + 'shift' + '-' | ズームイン/ズームアウト(個人設定) |
| 'option' + 'command' + 'enter' | セル内の改行 |
use strict;
use warnings;
use AnyEvent::Impl::Perl;
use AnyEvent;
print "start\n";
my $cv = AnyEvent->condvar;
my $io; $io = AnyEvent->io(
fh => \*STDIN, # 標準入力
poll => 'r', # 読み取り専用?
cb => sub {
print "cb start\n";
chomp(my $input =);
undef $io;
$cv->send($input); # send(....)を実行すると、recvの戻り値が入る
},
);
print "recv wait\n";
if (defined(my $input = $cv->recv)) { # sendの引数が戻り値として受け取れる
print "got: [$input]\n";
}
print "end\n";
perl sample.pl
start
recv wait
・・・ここで待たされる。
hogehoge[Enter] <= 入力する
cb start
got: [hogehoge]
end
use strict;
use warnings;
use AnyEvent::Impl::Perl;
use AnyEvent;
print "start\n";
my $cv = AnyEvent->condvar;
my $timer; $timer = AnyEvent->timer(
after => 3, # 3秒後に
interval => 1, # 1秒間隔
cb => sub {
print "cb start\n";
$cv->send;
},
);
print "wait\n";
$cv->recv; # 待機
print "end\n";
perl any_event_timer.pl
start
wait
(3秒後)
end
$( 対象オブジェクト ).everyTime( ミリ秒数 , '関数名'(省略可) , 関数命令 );
$( 対象オブジェクト ).stopTime( '関数名' , 関数命令(省略可) );
$( 対象オブジェクト ).oneTime( ミリ秒数 , '関数名'(省略可) , 関数命令 );
use strict;
use warnings;
use Test::More;
my %hash = ( key1 => 'val1', key2 => 'val2' );
# スライス
my ( $a, $b ) = @hash{qw/key1 key2/};
is $a, 'val1', 'val1';
is $b, 'val2', 'val2';
# keysを使っても取れるが、順番はランダム
my ( $a1, $b1 ) = @hash{ keys %hash };
is_deeply + { $a1 => 1, $b1 => 1 }, +{ 'val1' => 1, 'val2' => 1 }, "keys";
# ハッシュリファレンスでも使えます
my $hash = +{ key1 => 'val1', key2 => 'val2' };
my ( $a2, $b2 ) = @$hash{qw/key1 key2/};
is $a2, 'val1', 'hash ref val1';
is $b2, 'val2', 'hash ref val2';
# マージにも使えますね
my $hash1 = +{ key1 => 'val1', key2 => 'val2' };
my $hash2 = +{ key3 => 'val3', key4 => 'val4' };
my $ret = +{
key1 => 'val1',
key2 => 'val2',
key3 => 'val3',
key4 => 'val4',
};
@$hash2{ keys %$hash1 } = @$hash1{ keys %$hash1 };
is_deeply $hash2, $ret, 'merge';
# 単純なマージならこれでもできます
my $hash3 = +{ %$hash2, %$hash1 };
is_deeply $hash3, $ret, 'merge2';
done_testing;
前提 ReactNativeでiOS版のアプリをリリースしていて、Android版をリリースする話 トラブルシューティング Build.VERSION_CODES.Q が存在しないエラー compileSdkVersionを29以上にすると解決 メモリー足りないエラー Execu...