{"id":19863498,"url":"https://github.com/sandialabs/shell-logger","last_synced_at":"2025-05-02T04:31:05.803Z","repository":{"id":222562980,"uuid":"757061716","full_name":"sandialabs/shell-logger","owner":"sandialabs","description":"A Python package that allows you to interact with the shell, while logging various metadata, statistics, and trace information.","archived":false,"fork":false,"pushed_at":"2025-04-24T13:02:37.000Z","size":1583,"stargazers_count":2,"open_issues_count":23,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-24T14:23:15.587Z","etag":null,"topics":["replicability","reproducibility","scr-2873","scripting","snl-build-tools","snl-comp-science-libs","snl-other","snl-performance-workflow"],"latest_commit_sha":null,"homepage":"https://shell-logger.readthedocs.io","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sandialabs.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-02-13T19:17:53.000Z","updated_at":"2025-04-24T13:02:39.000Z","dependencies_parsed_at":"2024-04-29T18:27:46.923Z","dependency_job_id":"15e093a6-df47-4eb0-81e0-7641fee52308","html_url":"https://github.com/sandialabs/shell-logger","commit_stats":null,"previous_names":["sandialabs/shell-logger"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandialabs%2Fshell-logger","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandialabs%2Fshell-logger/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandialabs%2Fshell-logger/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandialabs%2Fshell-logger/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sandialabs","download_url":"https://codeload.github.com/sandialabs/shell-logger/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251986759,"owners_count":21675951,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["replicability","reproducibility","scr-2873","scripting","snl-build-tools","snl-comp-science-libs","snl-other","snl-performance-workflow"],"created_at":"2024-11-12T15:14:54.632Z","updated_at":"2025-05-02T04:31:05.789Z","avatar_url":"https://github.com/sandialabs.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"![Lines of code](https://sloc.xyz/github/sandialabs/shell-logger/?category=code)\n[![codecov](https://codecov.io/gh/sandialabs/shell-logger/branch/master/graph/badge.svg?token=FmDStZ6FVR)](https://codecov.io/gh/sandialabs/shell-logger)\n[![CodeFactor](https://www.codefactor.io/repository/github/sandialabs/shell-logger/badge/master)](https://www.codefactor.io/repository/github/sandialabs/shell-logger/overview/master)\n[![CodeQL](https://github.com/sandialabs/shell-logger/actions/workflows/github-code-scanning/codeql/badge.svg)](https://github.com/sandialabs/shell-logger/actions/workflows/github-code-scanning/codeql)\n[![Continuous Integration](https://github.com/sandialabs/shell-logger/actions/workflows/continuous-integration.yml/badge.svg)](https://github.com/sandialabs/shell-logger/actions/workflows/continuous-integration.yml)\n[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](CODE_OF_CONDUCT.md)\n[![GitHub contributors](https://img.shields.io/github/contributors/sandialabs/shell-logger.svg)](https://github.com/sandialabs/shell-logger/graphs/contributors)\n[![Documentation Status](https://readthedocs.org/projects/shell-logger/badge/?version=latest)](https://shell-logger.readthedocs.io/en/latest/?badge=latest)\n[![License](https://img.shields.io/badge/license-BSD_3_Clause-black)](LICENSE.md)\n[![Merged PRs](https://img.shields.io/github/issues-pr-closed-raw/sandialabs/shell-logger.svg?label=merged+PRs)](https://github.com/sandialabs/shell-logger/pulls?q=is:pr+is:merged)\n[![OpenSSF Best Practices](https://bestpractices.coreinfrastructure.org/projects/8863/badge)](https://bestpractices.coreinfrastructure.org/projects/8863)\n[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/sandialabs/shell-logger/badge)](https://securityscorecards.dev/viewer/?uri=github.com/sandialabs/shell-logger)\n![Platforms](https://img.shields.io/badge/Platforms-Linux%7CMacOS-orange)\n[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit)\n[![pre-commit.ci Status](https://results.pre-commit.ci/badge/github/sandialabs/shell-logger/master.svg)](https://results.pre-commit.ci/latest/github/sandialabs/shell-logger/master)\n[![PyPI - Version](https://img.shields.io/pypi/v/shell-logger-sandialabs?label=PyPI)](https://pypi.org/project/shell-logger-sandialabs/)\n![PyPI - Downloads](https://img.shields.io/pypi/dm/shell-logger-sandialabs?label=PyPI%20downloads)\n![Python Version](https://img.shields.io/badge/Python-3.9|3.10|3.11|3.12|3.13-blue.svg)\n[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)\n\n\u003e **NOTICE:**  After using this package for a few years, we realized we'd\n\u003e attempted to do too many things at once with it.  It still provides\n\u003e tremendous functionality for a wide variety of use cases, but for particular\n\u003e corner cases, it became apparent that design decisions made early on were\n\u003e hampering forward progress, and we wouldn't recommend doing things the same\n\u003e way today.  Certain aspects of its functionality have inspired more focused\n\u003e packages ([reverse-argparse][reverse-argparse],\n\u003e [staged-script][staged-script]), and we hope to do the same with more\n\u003e functionality in the future.  For the time being, though, don't expect much\n\u003e development and maintenance here.  That said, if you use `shell-logger` and\n\u003e are eager to contribute to its longevity, let us know.\n\n[reverse-argparse]:  https://github.com/sandialabs/reverse_argparse\n[staged-script]:  https://github.com/sandialabs/staged-script\n\n# shell-logger\n\nThe `shell-logger` Python package allows you to interact with the shell, while\nlogging various metadata, statistics, and trace information.  Any time you're\ntempted to write your own wrapper around things like `subprocess.Popen()` or\n`subprocess.run()`, consider using `shell_logger.ShellLogger.log()` instead.\nIf you're familiar with [the Unix script command][script], this is similar in\nprinciple, but with substantially more functionality.  If you're familiar with\n[Python's logging module][logging], the motivation is similar, but this intends\nto capture what's happening *in the shell* rather than in Python itself.\n\n[script]:  https://man7.org/linux/man-pages/man1/script.1.html\n[logging]:  https://docs.python.org/3/library/logging.html\n\n## Installation\n\nTo get up and running with `shell-logger`, simply:\n```bash\npython3 -m pip install shell-logger-sandialabs\n```\n\n## Usage\n\nOnce the package is installed, you can simply\n```python\nfrom shell_logger import ShellLogger\nsl = ShellLogger(\"Title of Log File\")\nsl.log(\"Execute my first command in the shell.\", \"echo 'Hello World'\")\nsl.finalize()\n```\n\nFor more detailed usage and API information, please see\n[our documentation][readthedocs].\n\n[readthedocs]:  https://shell-logger.readthedocs.io\n\n## Where to Get Help\n\nIf you're having trouble with `shell-logger`, or just want to ask a question,\nhead on over to [our issue board][issues].  If a quick search doesn't yield\nwhat you're looking for, feel free to file an issue.\n\n[issues]:  https://github.com/sandialabs/shell-logger/issues\n\n## Contributing\n\nIf you're interested in contributing to the development of `shell-logger`, we'd\nlove to have your help :grinning:  Check out our\n[contributing guidelines](CONTRIBUTING.md) for how to get started.\n[Past contributors][contributors] include:\n* [@bbraunj](https://github.com/bbraunj)\n* [@sswan](https://github.com/sswan)\n* [@dc-snl](https://github.com/dc-snl)\n* [@jmgate](https://github.com/jmgate)\n* [@mvlopri](https://github.com/mvlopri)\n\n[contributors]:  https://github.com/sandialabs/shell-logger/graphs/contributors\n\n## License \u0026 Copyright\n\nSee [LICENSE.md](LICENSE.md) and [COPYRIGHT.md](COPYRIGHT.md).\n\n## Credits\n\nSpecial thanks to the EMPIRE project for investing in the initial development\nof this tool, and [the GMS project][gms] for serving as a second user and\ncontributing to its clean-up.\n\n[gms]: https://github.com/SNL-GMS/GMS-PI25\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsandialabs%2Fshell-logger","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsandialabs%2Fshell-logger","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsandialabs%2Fshell-logger/lists"}