Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Create a redistributable .exe file for App-SFDC
perl -x %0 >
perlapp ^
--add MooX::Options::Role^
--add App::SFDC::Role::^
--add Log::Log4perl::Appender::Screen^
--add WWW::SFDC::^
--bind manifests/base.xml[file=C:\perl64\site\lib\auto\Share\dist\App-SFDC-Metadata\manifests\base.xml,text,mode=666]^
--bind manifests/all.xml[file=C:\perl64\site\lib\auto\Share\dist\App-SFDC-Metadata\manifests\all.xml,text,mode=666]^
--bind plugins/[file=C:\perl64\site\lib\auto\Share\dist\App-SFDC-Metadata\plugins\,text,mode=777]^
--scan C:\perl64\site\lib\auto\Share\dist\App-SFDC-Metadata\plugins\^
--bind certs/cafile.crt[file="C:\Program Files (x86)\Git\bin\curl-ca-bundle.crt",text,mode=666]^
--env HTTPS_CA_FILE=certs/cafile.crt^
--info CompanyName=Sophos;LegalCopyright="This software is Copyright (c) 2015 by Sophos Limited This is free software, licensed under the MIT (X11) License"^
--norunlib --force --exe SFDC.exe
goto :endofperl
use strict;
use warnings;
use 5.12.0;
use App::SFDC;
my $commandArrayDefinition = 'my @commands = ("'
. (join '","', @App::SFDC::commands) . '");';
say <<'HEAD';
package SFDC;
use strict;
use warnings;
say "use App::SFDC::Command::$_;" for @App::SFDC::commands;
say 'my @commands = ("' . (join '","', @App::SFDC::commands) . '");';
say <<'BODY';
my $usage = join "\n\n",
"SFDC: Tools for interacting with",
"Available commands:",
(join "\n", map {"\t$_"} @commands),
"For more detail, run: SFDC <command> --help";
my $command = shift;
exit 1 unless do {
if ($command) {
if (my ($correct_command) = grep {/^$command$/i} @commands) {
} else {
print $usage;
} else {
print $usage;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.