首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > JAVA > J2EE开发 >

这段代码什么意思啊该怎么处理

2014-01-17 
这段代码什么意思啊下面这段代码好像是是perl脚本,没接触过,大家能不能帮着解释下,谢谢了。#!/usr/bin/env

这段代码什么意思啊
下面这段代码好像是是perl脚本,没接触过,大家能不能帮着解释下,谢谢了。


#!/usr/bin/env perl

use Cwd qw(abs_path);
use File::Basename qw(dirname);

# include script functions
use vars qw(
$PREFIX
);
$PREFIX = abs_path(dirname($0));
require($PREFIX . "/functions.pl");

@profiles = ('default', 'full', 'dir');
if (-f $PREFIX . "/opennms-full-assembly/pom.xml") {
if (open (FILEIN, $PREFIX . "/opennms-full-assembly/pom.xml")) {
@profiles = ();
my $lastline = "";
while (my $line = <FILEIN>) {
chomp($line);
if ($lastline =~ /<name>build.profile<\/name>/) {
if ($line =~ /<value>(.*?)<\/value>/) {
push(@profiles, $1);
}
}
$lastline = $line;
}
close(FILEIN);
} else {
warning("unable to read from $PREFIX/opennms-full-assembly/pom.xml: $!");
}
}

if (not grep { $_ =~ /^-Dbuild.profile=/ } @ARGS) {
info("No build profile set, using the default.  Possible profiles are: " . join(", ", @profiles));
push(@ARGS, '-Dbuild.profile=default');
}

if (not grep { $_ =~ /^[^-]/ } @ARGS) {
debug("no maven targets specified, adding 'install' to the command-line");
push(@ARGS, "install");
}

my @command = ($MVN, @ARGS);
info("changing working directory to $PREFIX/opennms-full-assembly");
chdir($PREFIX . "/opennms-full-assembly");
info("running:", @command);
handle_errors_and_exit(system(@command));


看不懂
[解决办法]
没接触过就去学习一下吧:http://wenku.baidu.com/view/c8dbc908f12d2af90242e629.html
[解决办法]
楼主应该去http://bbs.csdn.net/forums/OL_Script里发这个帖子哦.
[解决办法]
这是java吗?还是什么语言啊?
[解决办法]


[解决办法]
看不懂。这个是c语言。
[解决办法]
楼主 你跑错板块了。。

热点排行