Giter Site home page Giter Site logo

Multiple printer config files about printrun HOT 9 CLOSED

snekya avatar snekya commented on June 26, 2024
Multiple printer config files

from printrun.

Comments (9)

DivingDuck avatar DivingDuck commented on June 26, 2024 1

Hi @snekya,

below you will find the command line options for Pronterface and how to use them with Windows:

Usage:
         pronterface [OPTIONS] [FILE]
       Options:
         -h, --help   ( Print this help message and exit )
         -V, --version   ( Print program's version number and exit )
         -v, --verbose   ( Increase verbosity )
         -a, --autoconnect   ( Automatically try to connect to printer on startup )
         -c, --conf, --config=CONFIG_FILE   ( Load this file on startup instead of .pronsolerc; you may chain config files, if so settings auto-save will use the last specified file )
         -e, --execute=COMMAND   ( Executes command after configuration/.pronsolerc is loaded; macros/settings from these commands are not autosaved")

pronterface [OPTIONS] [FILE]

in your case, if your config is in folder Desktop and the config file name is printer2:

Pronterface.exe -c "c:\Users\snekya\Desktop\printer2.ini"
or using the command line version
Pronsole.exe -c "c:\Users\snekya\Desktop\printer2.ini"

Copy an existing config file (printrunconf.ini) and rename it to your needs. You need to add the complete path and file name and put it in quotation marks as shown above.

Same for running from source (Pronterface.py / Pronsole.py )

from printrun.

snekya avatar snekya commented on June 26, 2024 1

Saved as a batch file. Great success. I learn something new every day. Thank you kindly!

from printrun.

DivingDuck avatar DivingDuck commented on June 26, 2024

Maybe one additional example, you can do in Windows also things like this:

%userprofile%\Downloads\pronterface-test\Pronterface.exe -c "%userprofile%\Downloads\printer2.ini"

This way you don't need to write/use the complete absolute path for an active user account.

from printrun.

snekya avatar snekya commented on June 26, 2024

Thank you very much for taking the time to help me! I value your time and I don't want to waste your time. I'm still trying to figure out how to get this to work. Pardon my lack of knowledge. I am trying to understand how to get it to run from command line. I apologize. Someone with more knowledge of this topic would probably fully understand these instructions. Am I changing the name of pronterface.py? Or am I entering this path into the pronterface.py file somewhere? I really appreciate your help.

from printrun.

snekya avatar snekya commented on June 26, 2024

OK! I got it to work with the second method you showed me. So I assume I can save that as a shortcut path and use that?

from printrun.

snekya avatar snekya commented on June 26, 2024

I have the correct path saved and I can type in that in explorer and it works with the config correctly. I am trying to now figure out how to save it as a shortcut of some kind.

from printrun.

snekya avatar snekya commented on June 26, 2024

I really appreciate your help! I am now running two different instances with separate configs and they are saving and loading correctly. If you have any tips on how to make these shortcuts I appreciate it. But, problem solved! thank you again.

from printrun.

DivingDuck avatar DivingDuck commented on June 26, 2024

Glad that you find a solution that works for you. It was too late for me (around 3 o'clock in the morning in my country). :)

Regarding shortcuts, You can create a desktop shortcut and then modify it in the way you need it. Here is an example how to run the command line version Pronsole.exe in a windows terminal. The screenshot is in German but I'm sure you find the same view in your language as well.
This is documented here: https://github.com/kliment/Printrun?tab=readme-ov-file#windows (look for ...Running Pronsole works best by running it in WindowsTerminal. ) You may want to install Windows Terminal if you don't have it already installed.

First create a desktop shortcut by [mouse right click] on a file like pronsole.exe. Then edit the Desktop shortcut by right clicking and select [Properties], choose the tab [Shortcut] and modify the the field [Target] and [Start in:]

Target (Ziel):
%LocalAppData%\Microsoft\WindowsApps\wt.exe --title Pronsole %USERPROFILE%\Downloads\pronterface-test\Pronsole.exe
Start in (Ausführen in:):
%USERPROFILE%\Downloads\pronterface-test

In this example I call windows Terminal with %LocalAppData%\Microsoft\WindowsApps\wt.exe, name the shortcut as Pronsole with --title Pronsole and run pronsole with %USERPROFILE%\Downloads\pronterface-test\Pronsole.exe. And when you extend this with your individual config file, like -c "%userprofile%\Downloads\printer2.ini" you will have what you need. In the same way you can start an executable binary file or Pronterface from code.
A lot of possible way's running Pronterface or Pronsole.

Pronsole Desktop shortcut

from printrun.

snekya avatar snekya commented on June 26, 2024

Thank you so much for your assistance and thoughtful reply. I will try this as well. The batch file worked great but I will do this as well to understand this better. I thank you once again for the thorough explanations and for taking the time to assist me with my issue.

from printrun.

Related Issues (20)

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.