sudo openssl x509 -req -days 365 -in $name.csr -signkey $name.key -out $name.crt
cat $name.crt $name.key > $name.pem
}
+
+urlencode() {
+ local length="${#1}"
+ for (( i = 0; i < length; i++ )); do
+ local c="${1:i:1}"
+ case $c in
+ [a-zA-Z0-9.~_-]) printf "$c" ;;
+ *) printf '%%%02X' "'$c"
+ esac
+ done
+}
+
+urldecode() {
+ local url_encoded="${1//+/ }"
+ printf '%b\n' "${url_encoded//%/\\x}"
+}
my $VERBOSE = $main::VERBOSE = 1;
my $DEBUG = $main::DEBUG = 0;
-my %Opt; get_options(\%Opt);
+my %Opt = (
+);
+get_options(\%Opt);
help() unless @ARGV;
$main::_DATA_ = undef;
return $v;
}
- $main::_DATA_ =~ s/([@\$][A-Z_]+)/pod_env($1)/eg;
+ $main::_DATA_ =~ s/([@\$][A-Z_a-z\{\}]+)/pod_env($1)/eg;
# Create tmp
my $in_file = (-e '/dev/shm' ? '/dev/shm' : '/tmp')."/$NAME.$$";
=head1 OPTIONS
- option[verbose|v+] Verbose mode: increase the verbosity level.
- option[debug+] Debug mode: increase the verbosity level.
- option[version|V] Print version (default: $VERSION)
- option[help|h|?] Print a brief help message and exits.
- option[man] Print the manual page and exits.
+ -option[verbose|v+] Verbose mode: increase the verbosity level.
+ -option[debug+] Debug mode: increase the verbosity level.
+ -option[version|V] Print version (default: $VERSION)
+ -option[help|h|?] Print a brief help message and exits.
+ -option[man] Print the manual page and exits.
=cut