Skip to content

Add dgt-converter package#224

Open
khaleeek wants to merge 6 commits into
espanso:mainfrom
khaleeek:main
Open

Add dgt-converter package#224
khaleeek wants to merge 6 commits into
espanso:mainfrom
khaleeek:main

Conversation

@khaleeek

@khaleeek khaleeek commented May 1, 2026

Copy link
Copy Markdown

This package converts standard date-time into DTG/DGT format using the :dgt trigger.

khaleeek added 6 commits May 1, 2026 15:20
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.

@khaleeek khaleeek left a comment

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

its okay

@smeech smeech requested a review from Copilot May 1, 2026 22:28

@smeech smeech left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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?

Comment thread packages/dgt-converter/0.1.0/_manifest.yml
Comment thread packages/dgt-converter/0.1.0/package.yml
Comment thread packages/dgt-converter/0.1.0/package.yml
Comment thread packages/dgt-converter/0.1.0/README.md
Comment thread packages/dgt-converter/0.1.0/package.yml
Comment thread packages/dgt-converter/0.1.0/README.md
Comment thread packages/dgt-converter/0.1.0/README.md
Comment thread packages/dgt-converter/0.1.0/package.yml

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.yml implementing a :dgt match with a form prompt and a PowerShell-based formatter.
  • Added _manifest.yml metadata 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.

Comment on lines +7 to +8
tags:
[

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not overly concerned about this as long as it's valid YAML.

Comment on lines +13 to +19
## Trigger

Type:

:dgt

A popup will appear asking for date and time.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I commented above #224 (comment), I think this needs addressing to make the package usable.

Comment on lines +16 to +17
$dt = [datetime]::ParseExact($x, "MMMM d, yyyy h:mm tt", $null)
$dt.ToString("ddHHmmMMMyy").ToUpper()
Comment on lines +16 to +17
$dt = [datetime]::ParseExact($x, "MMMM d, yyyy h:mm tt", $null)
$dt.ToString("ddHHmmMMMyy").ToUpper()
- name: output
type: shell
params:
shell: powershell

@smeech smeech May 16, 2026

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is tricky.

  • shell: powershell will work on most versions of Windows, but will only work (somewhat slowly) in Linux or macOS if pwsh is installed and either the line is changed to shell: pwsh or the user has "powershell" symlinked to pwsh. I like the explanation at the bottom of this page.
  • shell: pwsh may fail in some Windows instances if pwsh.exe isn't installed, so is not ideal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants