Home

Awesome

SourcetrailPerlIndexer

Perl Indexer for Sourcetrail based on PPI and SourcetrailDB

Description

The SourcetrailPerlIndexer project is a Sourcetrail language extension that brings Perl support to Sourcetrail. This project is still in a prototype state, but you can already run it on your Perl code!

Requirements

Setup

Running the Source Code

To index an arbitrary Perl source file, execute the command:

$ perl run.pl --source-file-path=path/to/your/perl/file.pl --database-file-path=path/to/output/database/file.srctrldb

This will index the source file and store the data to the provided database filepath. If the database does not exist, an empty database will be created.

You can access an overview that lists all available command line parameters by providing no arguments, which will print the following output to your console:

$ perl run.pl
Usage:
    run.pl [--help] [--man] [--version]
    --database-file-path=DATABASE_FILE_PATH
    --source-file-path=SOURCE_FILE_PATH [--clear] [--verbose]

     Options:

      --help                print brief help message and exit
      --man                 show full documentation and exit
      --version             print version of this program and exit
      --database-file-path  path to the generated Sourcetrail database file (required)
      --source-file-path    path to the generated Sourcetrail database file (required)
      --clear               clear the database before indexing
      --verbose             enable verbose console output

Running the Release

The available release packages already contain a functional Perl enviroment and all the dependencies. To index an arbitrary Perl source file just execute the command:

$ path/to/SourcetrailPerlIndexer --source-file-path=path/to/your/perl/file.pl --database-file-path=path/to/output/database/file.srctrldb

Executing the Tests

To run the tests for this project, execute the command:

$ prove

Contributing

If you like this project and want to get involved, there are lots of ways you can help:

To create a pull request, follow these steps:

Sourcetrail Integration

To run the perl indexer from within your Sourcetrail installation, follow these steps:

"pick custom sourcegroup""fill custom sourcegroup"