From 00ddde1541d68bf1398f7e176082622ecfd27cda Mon Sep 17 00:00:00 2001 From: Matias Linares Date: Sat, 11 Jul 2020 20:16:11 -0300 Subject: Use selective exporting for MAIN --- META6.json | 8 +++++--- bin/run-for-pid | 2 +- lib/App/RunForPid.pm6 | 4 ++-- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/META6.json b/META6.json index 571ac14..80798d5 100644 --- a/META6.json +++ b/META6.json @@ -4,8 +4,10 @@ "Matias Linares" ], "build-depends" : [ ], - "depends" : [ ], - "description" : "blah blah blah", + "depends" : [ + "Term::Choose" + ], + "description" : "Given a X Window, attach a process for debug (gdb, tail, etc)", "license" : "Artistic-2.0", "name" : "App::RunForPid", "perl" : "6.c", @@ -13,7 +15,7 @@ "App::RunForPid" : "lib/App/RunForPid.pm6" }, "resources" : [ ], - "source-url" : "", + "source-url" : "deprecated.org:/var/www/cgit/App-RunForPid.git", "tags" : [ ], "test-depends" : [ ], "version" : "0.0.1" diff --git a/bin/run-for-pid b/bin/run-for-pid index 71745c6..de1c121 100644 --- a/bin/run-for-pid +++ b/bin/run-for-pid @@ -1,3 +1,3 @@ #!/usr/bin/env raku -use App::RunForPid; +use App::RunForPid :main; diff --git a/lib/App/RunForPid.pm6 b/lib/App/RunForPid.pm6 index 7d45941..dbaa5a8 100644 --- a/lib/App/RunForPid.pm6 +++ b/lib/App/RunForPid.pm6 @@ -43,7 +43,7 @@ sub list-file-descriptors($pid) { } #| Find a pid for a window -multi sub MAIN() is export { +multi sub MAIN() is export(:main) { my $ppid = get-pid; my @actions = ; @@ -121,6 +121,6 @@ multi sub MAIN() is export { } #| Execute a command for a child process of $pid -multi sub MAIN(Int $pid) is export { +multi sub MAIN(Int $pid) is export(:main) { say "Running for $pid"; } -- cgit v1.2.3-70-g09d2