Jakob Voß > Data-Beacon-0.3.1 > beacon

Download:
Data-Beacon-0.3.1.tar.gz

Annotate this POD

Website

View/Report Bugs
Source  

NAME ^

beacon - beacon command line client

VERSION ^

version 0.3.1

SYNOPSIS ^

beacon [ <options> ] {KEY=VALUE} [ <command> <name> ] [ <file> ]

DESCRIPTION ^

This command line script can parse, test, and serialize BEACON files.

COMMANDS

The first command line argument is treated as command or as [file]name, if it does not match a known command. The following commands are recognized:

about

Print the meta fields. This command is the default, if no command is specified. Parsing BEACON file with this commands stops at the first non-meta line, so errors in the links will not be detected.

parse

Print the meta fields, possibly extended by automatically generated fields, such as COUNT after parsing the full BEACON file. Use this command to validate a BEACON file.

links

Parse a BEACON file and print all valid links.

dump

Parse a BEACON file and print all meta fields (possibly extended), followed by all valid links.

expand

Print all valid links in fully expanded form, without meta fields.

query

Query a BEACON file ore stored BEACON for an id (without prefix).

ARGUMENTS ^

  -file <name>   specify a BEACON file (use '-' for stdin)
  -name <name>   specify a name (for Beacons in a collection)
  -pre <file>    start with meta fields from a given BEACON file
  -mtime         use file's modification time if no TIMESTAMP given
  -test          enable test mode (no stored Beacon is modified)
  -quiet         suppress all error messages
  -help          brief help message
  -man           full documentation with examples
  -verbose       print additional messages
  -dbi <dbi>     database connection to a beacon collection
  -config <file> specify config file, e.g. for database connection

  about  <name>  show meta information about a file or stored beacon
  parse  <name>  parse a full BEACON file and print meta information
  dump   <name>  parse a BEACON file or dump a stored beacon
  links  <name>  only print links, without meta fields
  expand <name>  parse and expand a BEACON file or dump a stored Beacon
  query <name> <id> query a BEACON file or stored Beacon for an identifier

EXAMPLES ^

To show the meta fields of a BEACON file (command about):

  beacon about myfile

As about is the default command, alternatively you can use one of:

  beacon myfile
  beacon -file myfile
  beacon -file myfile about

To validate a BEACON file and show errors only:

  beacon parse myfile > /dev/null

Prepend meta fields from file mfields to BEACON file myfile. Use last modification time of myfile as TIMESTAMP if not included in myfile:

  beacon -pre myfields -mtime dump myfile

NOTE ^

The command name beacon clashes with a tool of same name from the ax25-tools package (http://www.linux-ax25.org/). If you need to use beacon together with hamradio, you need to rename one of the two scripts.

AUTHOR ^

Jakob Voß

COPYRIGHT AND LICENSE ^

This software is copyright (c) 2014 by Jakob Voß.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

syntax highlighting: