Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: bugs in scheduled task #125

Merged
merged 1 commit into from
Sep 1, 2024
Merged

fix: bugs in scheduled task #125

merged 1 commit into from
Sep 1, 2024

Conversation

sigoden
Copy link
Owner

@sigoden sigoden commented Sep 1, 2024

There are several bugs in the previously created scheduled task.

  • don't works with exe path with space
  • unexpected check the box Power > Start the task only if the computer is on AC power
  • unexpected check the box Settings > If the task is not scheduled to run again, delete it after

This is due to the fact that we used to create a task with schtasks /create /tn WindowSwitcher /tr $exe_path /sc onlogon /rl highest /it /f. Many options are set to defaults and cannot be changed.

Now we create a task with schtasks /create /tn WindowSwitcher /xml $xml_path /f, This method allows for precise control over all options and eliminates bugs.

close #124

@sigoden sigoden merged commit 4e29475 into main Sep 1, 2024
2 checks passed
@sigoden sigoden deleted the fix branch September 1, 2024 10:47
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.

Open on startup has issues
1 participant