diff options
| author | beatrice <beatrice@dangofactory.net> | 2026-11-22 20:01:35 +0900 |
|---|---|---|
| committer | beatrice <beatrice@dangofactory.net> | 2026-11-22 20:01:35 +0900 |
| commit | 6e93939f2b885f1f53836fa3e19b398a5ebbdf40 (patch) | |
| tree | 5fde91edefd5452acabd3e09426a5a47f232a64c /inc/Module/Install/Scripts.pm | |
| download | Text-Markdown-master.tar.gz Text-Markdown-master.zip | |
Import Text-Markdown-1.000031.tar.gzHEADlocal/Text-Markdownmaster
Diffstat (limited to 'inc/Module/Install/Scripts.pm')
| -rw-r--r-- | inc/Module/Install/Scripts.pm | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/inc/Module/Install/Scripts.pm b/inc/Module/Install/Scripts.pm new file mode 100644 index 0000000..a1001f5 --- /dev/null +++ b/inc/Module/Install/Scripts.pm @@ -0,0 +1,29 @@ +#line 1 +package Module::Install::Scripts; + +use strict 'vars'; +use Module::Install::Base (); + +use vars qw{$VERSION @ISA $ISCORE}; +BEGIN { + $VERSION = '0.91'; + @ISA = 'Module::Install::Base'; + $ISCORE = 1; +} + +sub install_script { + my $self = shift; + my $args = $self->makemaker_args; + my $exe = $args->{EXE_FILES} ||= []; + foreach ( @_ ) { + if ( -f $_ ) { + push @$exe, $_; + } elsif ( -d 'script' and -f "script/$_" ) { + push @$exe, "script/$_"; + } else { + die("Cannot find script '$_'"); + } + } +} + +1; |
