Print@SoC Python CLI
Python wrapper for the Print@SoC desktop app and MCP stdio server.
Installation
pip install print-at-soc
Commands
All command names launch the same wrapper:
print-at-soc
print-soc
psoc
Useful options:
print-soc --help
print-soc --version
print-soc --install
print-soc --path
print-soc --doctor
Submit a file without opening the desktop UI:
print-soc print assignment.pdf --printer psts-dx --copies 1
Inspect live SoC printing state:
print-soc printer list --username your-soc-id --ask-password
print-soc job list --printer psts-dx --json
print-soc quota show --json
The inspection commands support --server stu|stf, --host, --port,
--username, --password-stdin, --ask-password, --key-path, and the
PSOC_SSH_* environment variables listed below. Human-readable commands print
tables/key-value output; pass --json for scripts.
Virtual Printer
macOS and Linux can install a CUPS virtual printer queue named PrintAtSoC.
After installation, normal apps can print to Print@SoC Virtual Printer; the CUPS
backend forwards the spool file to the configured SoC SSH server and submits it
with remote lpr. The default remote queue is psts-dx; use --printer to
choose another SOCprint queue such as psc008-dx or psts-sx.
Install the Python package, configure SSH/default printer settings, and install the system queue:
pip install print-at-soc
print-soc --install-virtual-printer --username your-soc-id --ask-password --printer psts-dx
Configuration is stored in ~/.PrintAtSoC/virtual-printer.json with mode 0600.
Use --password-stdin instead of --ask-password for scripted setup, or use
--key-path for SSH key authentication. The default server is
stu.comp.nus.edu.sg; pass --server stf for staff accounts.
Useful virtual printer commands:
print-soc virtual-printer configure --server stu --username your-soc-id --ask-password --printer psts-dx
print-soc virtual-printer install
print-soc virtual-printer status
print-soc virtual-printer uninstall
# Backward-compatible flag forms remain available:
print-soc --configure-virtual-printer --server stu --username your-soc-id --ask-password --printer psts-dx
print-soc --install-virtual-printer
print-soc --virtual-printer-status
print-soc --uninstall-virtual-printer
Run cleanup before uninstalling the Python package:
print-soc --uninstall-virtual-printer
pip uninstall print-at-soc
pip uninstall only removes Python package files. It does not know about CUPS
queues, backend files, or Print@SoC config created outside package metadata.
Windows virtual printer support is not installed by this command. Windows needs the modern Print Support App/MSIX virtual printer path rather than a CUPS backend.
Start the MCP server over stdio:
print-soc mcp
psoc mcp
MCP mode requires the desktop binary to already be installed. Run print-soc --install first if needed.
MCP Environment Variables
connect_ssh can read credentials from arguments or these environment variables:
PSOC_SSH_SERVER=stu
PSOC_SSH_HOST=stu.comp.nus.edu.sg
PSOC_SSH_PORT=22
PSOC_SSH_USERNAME=your-soc-username
PSOC_SSH_PASSWORD=your-password
PSOC_SSH_KEY_PATH=/path/to/private/key
PSOC_SSH_KEY_PASSPHRASE=optional-passphrase
MCP Tools
connect_sshdisconnect_sshconnection_statuslist_print_queuescheck_print_quotacheck_printer_queuesubmit_pdf_print_job
submit_pdf_print_job requires confirm=true because it submits a real print job.
Requirements
- Python 3.8+
- macOS, Linux, or Windows x64/arm64 as supported by the released desktop binaries
- NUS SoC network access or VPN for SSH printing
0.1.1
- Fix Windows installer execution and MSI asset selection; report unsuccessful installations.
- Run
--doctorwithout downloading or launching the desktop app. - Support passphrase-protected SSH keys through Paramiko.
- Clean up uploaded print files when a remote print command fails.
The desktop application is downloaded separately from GitHub Releases. This Python package update does not replace the desktop release.
Metadata
Release files for print-at-soc 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| print_at_soc-0.1.1.tar.gz | 28.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| print_at_soc-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 58.0 kB
Release files / print_at_soc-0.1.1.tar.gz
| Download URL | print_at_soc-0.1.1.tar.gz |
|---|---|
| Size | 28.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
20ea07da5fd83b1266f42a76d526de08650b902760798ed26ef251d4c6156430
|
|
BLAKE2b-256 checksum How to use checksums |
955be2082fb6ea8813125a6f5b87b684624b5535ccb9117e62e4df5f6e15144b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.6
|
Release files / print_at_soc-0.1.1-py3-none-any.whl
| Download URL | print_at_soc-0.1.1-py3-none-any.whl |
|---|---|
| Size | 29.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
495a787ec2aa82d2d913e7552633a5a682a54e94e7683e05212192378b3bd3c7
|
|
BLAKE2b-256 checksum How to use checksums |
92d33290ae2a49de99b8efd4b5c60b0536cc0638fed265e0e6aa1fbca7dda397
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.6
|