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
FROM perl:5.26.1 | |
RUN useradd -m -s /bin/bash appuser \ | |
&& cpanm Carmel --notest | |
USER appuser | |
RUN mkdir -p /home/appuser/webapp | |
WORKDIR /home/appuser/webapp | |
COPY --chown=appuser:appuser webapp/cpanfile . |
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/env perl | |
use utf8; | |
use strict; | |
use warnings; | |
use feature 'say'; | |
use open qw/:encoding(utf8) :std/; | |
use Data::Printer {deparse => 1, caller_info => 1}; | |
# Perl入学式 2018 in東京 秋開講 第1回 ピザ会でのお題 | |
# |
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/env perl | |
use utf8; | |
use v5.16; | |
use strict; | |
use warnings; | |
use feature 'say'; | |
use Data::Printer {deparse => 1, caller_info => 1}; | |
use Web::Query; | |
use Text::Shirasu; |
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
package Slack::IncomingWebHooks; | |
use utf8; | |
use Moo; | |
use HTTP::Tiny; | |
use JSON::MaybeXS qw(JSON); | |
has url => (is => 'ro'); | |
has channel => (is => 'ro'); | |
has username => (is => 'ro'); |
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
package Mojolicious::Plugin::JSON_XS; | |
use Mojo::Base 'Mojolicious::Plugin'; | |
use Mojo::JSON::XS; | |
sub register { | |
no warnings 'redefine'; | |
*Mojo::JSON::new = sub { | |
shift; | |
Mojo::Base::new('Mojo::JSON::XS', @_); | |
}; |
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/env perl | |
use utf8; | |
use strict; | |
use warnings; | |
use feature qw(say); | |
binmode STDIN, ":encoding(UTF-8)"; # 標準入力 | |
binmode STDOUT, ":utf8"; # 標準出力 | |
binmode STDERR, ":utf8"; # 標準エラー出力 |
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/env perl | |
use utf8; | |
use Mojolicious::Lite; | |
use Mojo::ByteStream qw(b); | |
use Path::Class qw(file); | |
use Text::Markdown qw( markdown ); | |
use List::Util qw(min max); | |
app->secret(b(__FILE__)->sha1_sum); |
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/env perl | |
use utf8; | |
use strict; | |
use warnings; | |
binmode STDIN, ":utf8"; | |
binmode STDOUT, ":utf8"; | |
print "値1を入力してください>>>"; | |
chomp( my $x = <STDIN> ); |