{"id":14063723,"url":"https://github.com/PowerShellCrack/YetAnotherCMLoggerPSModule","last_synced_at":"2025-07-29T16:31:28.461Z","repository":{"id":111449992,"uuid":"500163864","full_name":"PowerShellCrack/YetAnotherCMLoggerPSModule","owner":"PowerShellCrack","description":"Another module that writes a log in cmtrace format but with an output","archived":false,"fork":false,"pushed_at":"2024-04-14T16:39:15.000Z","size":12,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-11T20:23:09.601Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PowerShellCrack.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-06-05T17:22:41.000Z","updated_at":"2023-10-31T00:21:24.000Z","dependencies_parsed_at":null,"dependency_job_id":"b1b84564-ee3c-4d94-9ac6-728763271bc9","html_url":"https://github.com/PowerShellCrack/YetAnotherCMLoggerPSModule","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/PowerShellCrack/YetAnotherCMLoggerPSModule","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PowerShellCrack%2FYetAnotherCMLoggerPSModule","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PowerShellCrack%2FYetAnotherCMLoggerPSModule/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PowerShellCrack%2FYetAnotherCMLoggerPSModule/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PowerShellCrack%2FYetAnotherCMLoggerPSModule/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PowerShellCrack","download_url":"https://codeload.github.com/PowerShellCrack/YetAnotherCMLoggerPSModule/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PowerShellCrack%2FYetAnotherCMLoggerPSModule/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267718274,"owners_count":24133448,"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","status":"online","status_checked_at":"2025-07-29T02:00:12.549Z","response_time":2574,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-08-13T07:03:28.572Z","updated_at":"2025-07-29T16:31:28.158Z","avatar_url":"https://github.com/PowerShellCrack.png","language":"PowerShell","funding_links":[],"categories":["PowerShell"],"sub_categories":[],"readme":"# YetAnotherCMLogger PowerShell module\n\nAnother module that writes a log in cmtrace format but with an output\n\n## Prerequisites\n\nNo prerequisites are need, however having the cmtrace.exe is useful to read log output\n\n\n## Cmdlets\n- **Get-YaCMLogFileName** --\u003e Grabs current log file\n- **Set-YaCMLogFileName** --\u003e Sets a log file (defaults to name of script calling the cmdlet)\n- **Restore-YaCMLogFileName** --\u003e restores to original log name and path\n- **Write-YaCMLogEntry** --\u003e Write a log entry in CMtrace compatible format\n\n## Install\n\n```powershell\nInstall-Module YetAnotherCMLogger -Force\nImport-Module YetAnotherCMLogger\n```\n\n## Examples\n\n```powershell\n#build global log fullpath\n$Global:LogFilePath = \"$env:Windir\\Logs\\Mylogfile_$(Get-Date -Format 'yyyy-MM-dd').log\"\n#or set path by just calling (this will use the name)\nSet-YaCMLogFileName\nWrite-YaCMLogEntry -Message 'this is a new message' -Severity 1 -Passthru\n\n\nFunction Test-output{\n    ${CmdletName} = $MyInvocation.InvocationName\n    Write-YaCMLogEntry -Message ('this is a new message from [{0}]' -f $MyInvocation.InvocationName) -Source ${CmdletName} -Severity 0 -Passthru\n}\nTest-output\n\n#Create entry in log with warning message and output to host in yellow\nWrite-YaCMLogEntry -Message 'this is a log entry from an warning' -Severity 2 -Passthru\n\n#Create entry in log with error and output to host in red\nWrite-YaCMLogEntry -Message 'this is a log entry from an error' -Severity 3 -Passthru\n\n#restore path (eg. c:\\windows\\logs\\YetAnotherCMLogger_2022-06-05_T02-01-47-PM.log)\nRestore-YaCMLogFileName\nWrite-YaCMLogEntry -Message 'this is a log entry from success' -Severity 1  -Passthru\n\n#Set path to c:\\ with no appendix to log. (eg. c:\\Logs\\MyPoshScript.log).\nSet-YaCMLogFileName -ParentPath c:\\Logs -CallerName 'MyPoshScript' -Appendix ''\n\n#Retrieve current log path\nGet-YaCMLogFileName\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPowerShellCrack%2FYetAnotherCMLoggerPSModule","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FPowerShellCrack%2FYetAnotherCMLoggerPSModule","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPowerShellCrack%2FYetAnotherCMLoggerPSModule/lists"}