#!/usr/bin/perl use strict; use warnings; # Copyright 2013, 2017, Michael Allan. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Votorola Software"), to deal in the Votorola Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicence, and/or sell copies of the Votorola Software, and to permit persons to whom the Votorola Software is furnished to do so, subject to the following conditions: The preceding copyright notice and this permission notice shall be included in all copies or substantial portions of the Votorola Software. THE VOTOROLA SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE VOTOROLA SOFTWARE OR THE USE OR OTHER DEALINGS IN THE VOTOROLA SOFTWARE. =pod =head1 NAME gwt-codeserver - launch the codeserver for "super" development mode =head1 SYNOPSIS votorola/b/build x [xgwt [--module=I | --module='I I...']] votorola/b/gwt-codeserver [--verbose] I & http://localhost:9876/ votorola/b/gwt-codeserver --help | --man =head1 EXAMPLES votorola/b/gwt-codeserver votorola.s.gwt.wic.DIn & votorola/b/gwt-codeserver votorola.s.gwt.wic.DIn votorola.s.gwt.pollwiki.PollwikiIn & =cut sub _shift_options(); # # Shifts command line options into %votorola::b::Build::option. # { use votorola::b::GWT qw( codeserver ); _shift_options; codeserver(); } =pod =head1 OPTIONS =cut sub _shift_options() { use Getopt::Long (); use Pod::Usage qw( pod2usage ); use votorola::b::Build qw( %option ); use votorola::b::Console qw( $verbosity ); my @specification; push @specification, 'help|?'; =pod =over 8 =item --B Outputs a brief help message for both this wrapper and the code server. =cut push @specification, 'man'; =pod =item --B Outputs the full manual page for this wrapper and exits. =cut push @specification, 'verbose'; =pod =item --B Increases the level of console output. =cut Getopt::Long::Configure( 'pass_through' ); # pass unrecognized options through to CodeServer Getopt::Long::GetOptions( \%option, @specification ) or pod2usage( -verbose => 0 ); # and exits defined $option{'man'} and pod2usage( -verbose => 2 ); # and exits defined $option{'help'} and pod2usage( -verbose => 1, -exitval => 'NOEXIT' ); defined $option{'verbose'} and $verbosity = 1; } =pod =back =head1 SEE ALSO Super dev mode instructions - http://stackoverflow.com/a/18333050/2402790 Super dev mode in general - http://www.gwtproject.org/articles/superdevmode.html votorola/b/gwt-devmode - Obsolete, but it has info on serving a bundled Google module. =cut