Metadata-Version: 2.4
Name: batchtsocmd
Version: 0.1.7
Summary: Run TSO commands via IKJEFT1B
Author: Mike Fulton
License: Apache-2.0
Project-URL: Homepage, https://github.com/MikeFultonDev/batchtsocmd
Project-URL: Repository, https://github.com/MikeFultonDev/batchtsocmd
Project-URL: Issues, https://github.com/MikeFultonDev/batchtsocmd/issues
Keywords: zos,tso,mainframe,ebcdic,ikjeft1b
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: System Administrators
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: Other OS
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: System :: Systems Administration
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: zoautil-py
Requires-Dist: zos-ccsid-converter>=0.1.8
Requires-Dist: packaging>=20.0
Provides-Extra: dev
Requires-Dist: pytest>=7.0.0; extra == "dev"
Requires-Dist: build>=0.10.0; extra == "dev"
Requires-Dist: twine<4.0.0,>=3.0.0; extra == "dev"
Requires-Dist: readme-renderer<35.0,>=21.0; extra == "dev"
Provides-Extra: test
Requires-Dist: pytest>=7.0.0; extra == "test"
Dynamic: license-file

# batchtsocmd

Run TSO commands via IKJEFT1B with automatic encoding conversion.

## Description

`batchtsocmd` is a Python utility for z/OS that executes TSO commands through IKJEFT1B with automatic ASCII/EBCDIC encoding conversion. It handles SYSIN and SYSTSIN inputs from files, automatically converting them to EBCDIC as needed.

## Features

- Execute TSO commands via IKJEFT1B
- Automatic ASCII to EBCDIC conversion for input files
- Optional STEPLIB support
- Configurable output destinations (SYSTSPRT, SYSPRINT)
- Verbose mode for debugging

## Requirements

- Python 3.8 or higher
- z/OS operating system
- IBM Z Open Automation Utilities (ZOAU)
- zoautil-py package
- zos-ccsid-converter package

## Installation

**Note:** This package can only be installed and run on z/OS systems.

```bash
pip install batchtsocmd
```

## Usage

### Basic Usage

```bash
batchtsocmd --systsin systsin.txt --sysin input.txt
```

### With Output Files

```bash
batchtsocmd --systsin systsin.txt --sysin input.txt \
            --systsprt output.txt --sysprint print.txt
```

### With STEPLIB and Verbose Output

```bash
batchtsocmd --systsin systsin.txt --sysin input.txt \
            --steplib DB2V13.SDSNLOAD --verbose
```

## Command Line Options

- `--systsin PATH` - Path to SYSTSIN input file (required)
- `--sysin PATH` - Path to SYSIN input file (required)
- `--systsprt PATH` - Path to SYSTSPRT output file or 'stdout' (optional, defaults to stdout)
- `--sysprint PATH` - Path to SYSPRINT output file or 'stdout' (optional, defaults to stdout)
- `--steplib DATASET` - Optional STEPLIB dataset name (e.g., DB2V13.SDSNLOAD)
- `-v, --verbose` - Enable verbose output

## Notes

- Input files can be ASCII (ISO8859-1) or EBCDIC (IBM-1047)
- Encoding is auto-detected via file tags; untagged files are assumed to be EBCDIC
- Output files will be tagged as IBM-1047
- Both --systsprt and --sysprint default to 'stdout'
- When stdout is used, SYSTSPRT output is written first, then SYSPRINT output

## License

Apache License 2.0

## Author

Mike Fulton
