On 08/10/12 18:00, rt-users-requ...@lists.bestpractical.com wrote:
Send rt-users mailing list submissions to
        rt-users@lists.bestpractical.com

To subscribe or unsubscribe via the World Wide Web, visit
        http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
or, via email, send a message with subject or body 'help' to
        rt-users-requ...@lists.bestpractical.com

You can reach the person managing the list at
        rt-users-ow...@lists.bestpractical.com

When replying, please edit your Subject line so it is more specific
than "Re: Contents of rt-users digest..."


Today's Topics:

    1. testing perl script in RT (Gergely Buday)
    2. Re: testing perl script in RT (Paul Tomblin)
    3. Re: testing perl script in RT (Thomas Sibley)
    4. Re: testing perl script in RT (Thomas Sibley)
    5. Re: testing perl script in RT (Paul Tomblin)
    6. Re: testing perl script in RT (Thomas Sibley)
    7. HTML emails and attachments (Josh Hopkins)
    8. Re: rt-users Digest, Vol 101, Issue 9 (Wolfram Huettermann)
    9. Email notification of updates (Mark Goodge)
   10. Re: Email notification of updates (k...@rice.edu)
   11. Re: Email notification of updates (Mark Goodge)
   12. Re: Email notification of updates (k...@rice.edu)
   13. Re: Email notification of updates (Mark Goodge)
   14. incoming mail with attachement Permission Denied (Leon Berkers)


----------------------------------------------------------------------

Message: 1
Date: Thu, 9 Aug 2012 18:01:33 +0200
From: Gergely Buday<gbu...@gmail.com>
To: rt-users@lists.bestpractical.com
Subject: [rt-users] testing perl script in RT
Message-ID:
        <ca+3iozkqt_yopimrzc1vft1sdz7csmdjfvexjf4+imjkol+...@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1

Hi there,

how can I run a perl script through the RT environment so that I can
use the database and all the modules, but see the compiler output on
my faulty experiments?

- Gergely


------------------------------

Message: 2
Date: Thu, 9 Aug 2012 12:03:43 -0400
From: Paul Tomblin<ptomb...@xcski.com>
To: Gergely Buday<gbu...@gmail.com>
Cc: rt-users@lists.bestpractical.com
Subject: Re: [rt-users] testing perl script in RT
Message-ID:
        <cajcd8l8ahua53wnns+4rlyextc5yphh8svebrz7weogmz6x...@mail.gmail.com>
Content-Type: text/plain; charset="iso-8859-1"

On Thu, Aug 9, 2012 at 12:01 PM, Gergely Buday<gbu...@gmail.com>  wrote:

Hi there,

how can I run a perl script through the RT environment so that I can
use the database and all the modules, but see the compiler output on
my faulty experiments?

- Gergely

use lib "/opt/rt4/lib";
use RT;

That should be enough.

Hello I use a perl template like this:


#!/usr/bin/perl -w
# notwendige Header Anfang
use strict;

use lib "/opt/rt4/local/lib",  "/opt/rt4/lib";


use RT;
use RT::Interface::Web;

# Load the config file
use RT::Interface::CLI "GetCurrentUser", "loc", ;
RT::LoadConfig();

# Connect to the database and get RT::SystemUser
#  loaded
RT::Init();

### Put here all other PERL modules you need or whereever you want.


Greetings,


Wolfram


Reply via email to