Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Feb 2, 2026

Problem

Compiling workflows with only markdown changes (no frontmatter changes) rewrites lock files with identical content, updating timestamps and causing git to flag them as modified. This triggers false warnings about uncommitted files.

Changes

Compiler behavior (pkg/workflow/compiler.go)

  • Compare generated lock file content with existing file before writing
  • Skip write operation if content identical, preserving timestamp
  • Only write when content differs

Test coverage (pkg/workflow/compiler_skip_write_test.go)

  • Verify timestamp preservation when markdown-only changes
  • Verify timestamp update when frontmatter changes
  • Verify lock file creation when missing

Result

# Change only markdown content
$ vim workflow.md  # Edit description, no frontmatter change
$ gh aw compile workflow.md
✓ workflow.md (25.0 KB)

$ git status
Changes not staged for commit:
  modified: workflow.md
# Lock file not shown - content unchanged, timestamp preserved

# Change frontmatter
$ vim workflow.md  # Add permission
$ gh aw compile workflow.md
✓ workflow.md (25.1 KB)

$ git status
Changes not staged for commit:
  modified: workflow.md
  modified: workflow.lock.yml
# Both files shown - content changed, timestamp updated
Original prompt

Only changes to markdown were made so workflow did not produce a new yml on compile. But still we get a warning: https://docs.github.com/en/issues/planning-and-tracking-with-projects/learning-about-projects/about-projects If the frontmatter was not changed, not yml update should be required in the same commit/sha.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 4 commits February 2, 2026 09:58
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix warning related to markdown changes Skip lock file write when content unchanged to preserve timestamps Feb 2, 2026
Copilot AI requested a review from mnkiefer February 2, 2026 10:07
@mnkiefer mnkiefer marked this pull request as ready for review February 2, 2026 10:12
@mnkiefer mnkiefer merged commit 243a74e into main Feb 2, 2026
123 checks passed
@mnkiefer mnkiefer deleted the copilot/fix-markdown-warning-issue branch February 2, 2026 10:15
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.

2 participants