3

Perl 模块路径指定(调试环境)

 2 years ago
source link: https://blog.frytea.com/archives/561/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Perl 模块路径指定(调试环境)

August 25, 2021 • Read: 82 • 编程开发

本文首发于: https://blog.frytea.com/archives/561/

在调试 Perl 测试程序时,常常需要在测试路劲执行 Perl 脚本,相应的 .pm 模块测试程序也需并不在 Perl 默认的模块路径下,使用以下语句即可指定模块检索路径。

#!/usr/bin/perl
use lib './';
use Person;
# Person 包模块与当前脚本同级,可用上面两行代码指定包位置

---------------------
Author: Frytea
Title: Perl 模块路径指定(调试环境)
Link: https://blog.frytea.com/archives/561/
Copyright: This work by TL-Song is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK