Skip to content

ci: simplify artifact staging workflow - #27

Merged
beenycool merged 2 commits into
masterfrom
ci-cleanup
Apr 17, 2026
Merged

ci: simplify artifact staging workflow#27
beenycool merged 2 commits into
masterfrom
ci-cleanup

Conversation

@beenycool

@beenycool beenycool commented Apr 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • Remove PsExec download and RunAsAdmin.bat creation from CI
  • Stage only release files without PDB/obj noise

Summary by CodeRabbit

  • Chores
    • Simplified build artifact preparation and removed elevation tooling from release packages.

@gemini-code-assist

Copy link
Copy Markdown

Note

Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@coderabbitai

coderabbitai Bot commented Apr 12, 2026

Copy link
Copy Markdown

Warning

Rate limit exceeded

@beenycool has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 55 minutes and 8 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 55 minutes and 8 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 9a63966e-d38c-439d-895d-bc02442fe5b8

📥 Commits

Reviewing files that changed from the base of the PR and between 52c2fe1 and 507fd8d.

📒 Files selected for processing (1)
  • .github/workflows/dotnet-desktop.yml

Walkthrough

The GitHub Actions workflow's artifact preparation step is simplified by removing PSTools/PsExec-related logic and admin elevation control flow. Only directory creation and binary/config copying operations remain, with added error tolerance for one file.

Changes

Cohort / File(s) Summary
CI Workflow Artifact Preparation
.github/workflows/dotnet-desktop.yml
Removed PSTools/PsExec download, extraction, and admin launcher generation. Simplified Prepare Artifacts step to directory creation and binary/config copying. Added -ErrorAction SilentlyContinue to config file copy operation.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 PSTools and scripts are gone, away!
Admin elevation had its day.
Now artifacts prepare so clean,
The simplest build I've ever seen! 🎉

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'ci: simplify artifact staging workflow' directly and accurately summarizes the main change: removing PsExec/RunAsAdmin logic and simplifying artifact preparation in the CI workflow.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ci-cleanup

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Comment thread .github/workflows/dotnet-desktop.yml Outdated

Copy-Item "$out/AsusFanControl.exe" $stage
Copy-Item "$out/AsusFanControl.exe.config" $stage
Copy-Item "$out/AsusFanControl.exe.config" $stage -ErrorAction SilentlyContinue

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

WARNING: Using -ErrorAction SilentlyContinue may mask missing file errors. If AsusFanControl.exe.config is not generated in release builds, the error will be silently ignored, potentially leading to missing configuration in the artifact.

@kilo-code-bot

kilo-code-bot Bot commented Apr 12, 2026

Copy link
Copy Markdown

Code Review Summary

Status: 1 WARNING Issue Found | Recommendation: Address before merge

Overview

Severity Count
CRITICAL 0
WARNING 1
SUGGESTION 0

WARNING

File Line Issue
.github/workflows/dotnet-desktop.yml 72 Using -ErrorAction SilentlyContinue may mask missing file errors. If AsusFanControl.exe.config is not generated in release builds, the error will be silently ignored, potentially leading to missing configuration in the artifact.

Other Observations

  • The removal of PsExec and RunAsAdmin.bat simplifies the artifact preparation, which is a positive change.
  • Debug output is preserved, which may be useful for troubleshooting.
Files Reviewed (1 file)
  • .github/workflows/dotnet-desktop.yml - 1 issue

Reviewed by trinity-large-thinking · 96,968 tokens

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.github/workflows/dotnet-desktop.yml:
- Around line 67-69: Wrap the recursive file listing so it only runs when
debugging is enabled or on failure: check an environment flag like CI_DEBUG (or
run the listing in the failure branch) before executing the
Write-Host/Get-ChildItem $out -Recurse | ForEach-Object { Write-Host $_.FullName
} block; update the workflow to conditionally run that block when $env:CI_DEBUG
is truthy (or when the previous step failed) to avoid unconditional log bloat.
- Line 72: The PowerShell packaging step currently uses Copy-Item
"$out/AsusFanControl.exe.config" $stage -ErrorAction SilentlyContinue which
hides a missing config; change it so the job fails if the config is absent by
either removing -ErrorAction SilentlyContinue and using -ErrorAction Stop on
that Copy-Item invocation or by adding an explicit Test-Path check for
"$out/AsusFanControl.exe.config" and throwing/exit-ing with a non-zero code when
it's not found, ensuring the pipeline fails fast when the config is missing.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 2cbe50e3-b5d6-4f72-9559-d72666b893a4

📥 Commits

Reviewing files that changed from the base of the PR and between a469e19 and 52c2fe1.

📒 Files selected for processing (1)
  • .github/workflows/dotnet-desktop.yml

Comment thread .github/workflows/dotnet-desktop.yml Outdated
Comment thread .github/workflows/dotnet-desktop.yml Outdated

Copy-Item "$out/AsusFanControl.exe" $stage
Copy-Item "$out/AsusFanControl.exe.config" $stage
Copy-Item "$out/AsusFanControl.exe.config" $stage -ErrorAction SilentlyContinue

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Verify whether App.config is present/declared and likely required.
fd -i 'app.config'
rg -n -C2 --iglob '*.csproj' 'App\.config|None Include=.*App\.config|Content Include=.*App\.config'
rg -n -C2 --iglob '*.cs' 'ConfigurationManager|AppSettings|ConnectionStrings'

Repository: beenycool/AsusFanControl

Length of output: 423


🏁 Script executed:

# Read the workflow file around line 72 to understand context
cat -n .github/workflows/dotnet-desktop.yml | sed -n '60,85p'

Repository: beenycool/AsusFanControl

Length of output: 998


🏁 Script executed:

# Search for references to exe.config and build output directories in the workflow
rg -n 'exe\.config|AsusFanControl.exe|out\$|$out' .github/workflows/dotnet-desktop.yml

Repository: beenycool/AsusFanControl

Length of output: 212


🏁 Script executed:

# Check if App.config has any actual configuration content that would be needed
head -30 AsusFanControlGUI/App.config

Repository: beenycool/AsusFanControl

Length of output: 1513


Fail fast when AsusFanControl.exe.config is missing.

The -ErrorAction SilentlyContinue flag silently masks packaging failures. The config file contains critical runtime settings (.NET 4.7.2) and application defaults (fanSpeed, turnOffControlOnExit, forbidUnsafeSettings, etc.) required for the application to function correctly. If the build fails to produce the config, the artifact becomes broken—but the CI pipeline won't catch it.

Replace with explicit handling:

Safer approach
-        Copy-Item "$out/AsusFanControl.exe.config" $stage -ErrorAction SilentlyContinue
+        if (Test-Path "$out/AsusFanControl.exe.config") {
+          Copy-Item "$out/AsusFanControl.exe.config" $stage
+        } else {
+          Write-Warning "AsusFanControl.exe.config not found in $out"
+        }

Or, if the config is required (recommended):

-        Copy-Item "$out/AsusFanControl.exe.config" $stage -ErrorAction SilentlyContinue
+        Copy-Item "$out/AsusFanControl.exe.config" $stage  # Will fail if missing
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
Copy-Item "$out/AsusFanControl.exe.config" $stage -ErrorAction SilentlyContinue
if (Test-Path "$out/AsusFanControl.exe.config") {
Copy-Item "$out/AsusFanControl.exe.config" $stage
} else {
Write-Warning "AsusFanControl.exe.config not found in $out"
}
Suggested change
Copy-Item "$out/AsusFanControl.exe.config" $stage -ErrorAction SilentlyContinue
Copy-Item "$out/AsusFanControl.exe.config" $stage # Will fail if missing
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/dotnet-desktop.yml at line 72, The PowerShell packaging
step currently uses Copy-Item "$out/AsusFanControl.exe.config" $stage
-ErrorAction SilentlyContinue which hides a missing config; change it so the job
fails if the config is absent by either removing -ErrorAction SilentlyContinue
and using -ErrorAction Stop on that Copy-Item invocation or by adding an
explicit Test-Path check for "$out/AsusFanControl.exe.config" and
throwing/exit-ing with a non-zero code when it's not found, ensuring the
pipeline fails fast when the config is missing.

- Remove PsExec download and RunAsAdmin.bat creation
- Stage only release files (no PDB/obj noise)
@beenycool
beenycool merged commit cfc789b into master Apr 17, 2026
2 checks passed
@beenycool
beenycool deleted the ci-cleanup branch April 17, 2026 07:18
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.

1 participant