Add dgt-converter package#224
Conversation
mainfest
Added metadata for the DGT Time Converter including name, title, description, version, author, homepage, and tags.
Added README with usage example for DGT Time Converter.
Updated README to clarify DTG format and example usage.
main package create by me
smeech
left a comment
There was a problem hiding this comment.
A simple package including one trigger and a short, benign Powershell script.
I'll let Copilot do its stuff and will run the automated checks, but I have made a few minor suggestions for consideration, please?
There was a problem hiding this comment.
Pull request overview
Adds a new Espanso package (dgt-converter) that converts a user-provided date/time into a DGT/DTG-style string via the :dgt trigger.
Changes:
- Added
package.ymlimplementing a:dgtmatch with a form prompt and a PowerShell-based formatter. - Added
_manifest.ymlmetadata for publishing/discovery (name/title/version/tags). - Added a versioned README with usage example and installation instructions.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| packages/dgt-converter/0.1.0/package.yml | Defines the trigger, form input, and shell command to parse/format the date-time. |
| packages/dgt-converter/0.1.0/_manifest.yml | Declares package metadata (version, description, tags) for the package index. |
| packages/dgt-converter/0.1.0/README.md | Documents the trigger, example input/output, and installation. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| tags: | ||
| [ |
There was a problem hiding this comment.
I'm not overly concerned about this as long as it's valid YAML.
| ## Trigger | ||
|
|
||
| Type: | ||
|
|
||
| :dgt | ||
|
|
||
| A popup will appear asking for date and time. |
There was a problem hiding this comment.
As I commented above #224 (comment), I think this needs addressing to make the package usable.
| $dt = [datetime]::ParseExact($x, "MMMM d, yyyy h:mm tt", $null) | ||
| $dt.ToString("ddHHmmMMMyy").ToUpper() |
| $dt = [datetime]::ParseExact($x, "MMMM d, yyyy h:mm tt", $null) | ||
| $dt.ToString("ddHHmmMMMyy").ToUpper() |
| - name: output | ||
| type: shell | ||
| params: | ||
| shell: powershell |
There was a problem hiding this comment.
This is tricky.
shell: powershellwill work on most versions of Windows, but will only work (somewhat slowly) in Linux or macOS ifpwshis installed and either the line is changed toshell: pwshor the user has "powershell" symlinked topwsh. I like the explanation at the bottom of this page.shell: pwshmay fail in some Windows instances ifpwsh.exeisn't installed, so is not ideal.
This package converts standard date-time into DTG/DGT format using the :dgt trigger.