Novell is now a part of Micro Focus

Easy paste to

Novell Cool Solutions: Cool Tool

Digg This - Slashdot This

In Brief

Paste file content from Stardard Input to


Functional Categories:
  • Shortcuts
  • Workgroup
  • Posted:12 Dec 2005
    File Size:2.5KB
    Publisher:Fred Blaise


    Please read the note from our friends in legal before using this file.


    Fed up with:
    - Selecting your text
    - Going to website
    - Paste your text
    - Submit
    - Copy the URL you got back
    - Paste that link to IRC, or whatever ?

    My script gives you the ability to copy a file's content directly from command line, and it returns the URL back to you, saving you precious steps. It will also accepts stuff from STDIN. Examples:

    me@mybox#: ./ myfilename.conf
    Your paste URL is:
    df -h | ./
    Your paste URL is:

    If the script breaks for you, it may mean the code on has changed. Send me an email, and I will look at your problem. Avoid sending me emails because you have missing perl modules. Read the requirements.

    The following command line arguments are accepted:

    ./ \
    	--content "SOME STRING" \
    	--description "SOME STRING" \
    	--type INTEGER \
    	--expiry "SOME STRING" \
    	--name "YOUR NAME"

    See below for the "expiry" and "type" of text options.

    It requires Perl, WWW::Mechanize, and Getopt::Long.
    Defaults arguments values:
    - 30 minutes expiry
    - Raw text
    - clueless (your name ;))
    - description "-- automated paste by chapeaurouge
    Types of text:
    1/Raw -- DEFAULT
    2/Asterisk Configuration
    3/C Source
    4/C++ Source
    5/PHP Source
    6/Perl Source
    7/Java Source
    8/Visual Basic Source
    9/C# Source
    10/Ruby Source
    11/Python Source
    12/Pascal Source
    13/mIRC Script
    14/PL/I Source
    15/XML Document
    16/SQL Statement
    17/Scheme Source
    18/Action Script
    19/Ada Source
    20/Apache Configuration
    21/Assembly (NASM)
    23/BASH Script
    25/Delphi Source
    26/HTML 4.0 Strict
    28/LISP Source
    29/Lua Source
    30/Microprocessor ASM
    31/Objective C
    32/Visual Basic .NET
    Expiry times:
    Never -- DEFAULT
    5 minutes
    10 minutes
    15 minutes
    30 minutes
    45 minutes
    1 hour
    2 hours
    4 hours
    8 hours
    12 hours
    1 day
    2 days
    3 days
    1 week
    2 weeks
    3 weeks
    1 month
    2 months
    3 months
    4 months
    5 months
    6 months
    1 year

    Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions.

    © Copyright Micro Focus or one of its affiliates