Git Product home page Git Product logo

importhpuxprinter's Introduction

GitHub go.mod Go version of a Go moduleShell Script

ImportHPUXPrinter

This is a simple application to import HP-UX Printer in CUPS Linux Spooler.

Prerequisites

Before you get started, you’ll need to have these things:

The repository contains the following files:

  • HPUX/CreateListPrinter.sh : script to capture physical and logical printers under HP-UX
  • src/SetPrinter.go : source of the go script
  • SetPrinter : binary of the go script
  • config.json : configuration file of the script
  • template.sh: backend template file

Initial setup

Clone the repository :

[archi@mercure] git clone https://github.com/colussim/ImportHPUXPrinter.git

Copy the HPUX directory to the HP-UX server

Setup

You will find 1 configuration files :

config.json : configuration file with the following parameters:

{

    "FilePhysical" : "PhyPrinterList.csv",  Name of the file containing the names and ip addresses of the physical printers
    "FileLogical": "LogPrinterList.csv",    Name of the file containing the names of the logical printers
    "Template":"template.sh",               Name of the template file for the definition of the backends
    "Fprinter":"/usr/lib/cups/backend/",    Directory where the backends are stored
    "Description" :" MAGELLAN-"             Description added when creating the printer 

}

Usage

On HP-UX server run the script :

[root@bandol HPUX]./CreateListPrinter.sh

This script generates two files in csv format:

  • PhyPrinterList.csv
  • LogPrinterList.csv

Copy these two files into the directory of the Linux server where the repository was cloned.

On Linux server run the script :

[archi@mercure ImportHPUXPrinter]sudo ./SetPrinter

This script reads:

  • the PhyPrinterList.csv and LogPrinterList.csv files
  • creates the printers backend files
  • adds the logical printers if they exist as well as the physical printers

importhpuxprinter's People

Contributors

colussim avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.