Skip to content

Add log message to inform user of DevCommand being used in tauri-cli#12438

Merged
amrbashir merged 3 commits intotauri-apps:devfrom
3lpsy:dev
Jan 18, 2025
Merged

Add log message to inform user of DevCommand being used in tauri-cli#12438
amrbashir merged 3 commits intotauri-apps:devfrom
3lpsy:dev

Conversation

@3lpsy
Copy link
Contributor

@3lpsy 3lpsy commented Jan 18, 2025

This PR adds a simple log message to output the cargo command that is being used when running cargo tauri dev. There is only a single line of code added to desktop::run_dev:

  log::info!(action = "Running"; "DevCommand (`{} {}`)", &dev_cmd.get_program().to_string_lossy(), dev_cmd.get_args().map(|arg| arg.to_string_lossy()).fold(String::new(), |acc, arg| format!("{acc} {arg}")));

Reasoning:
I was having trouble determining what was happening at runtime and what "magic" the cargo tauri dev command was doing. Explicitly stating what's being run could be useful to others who are unfamiliar with the tauri-cli (like myself) to more easily determine what the CLI is actually doing. If you disagree and think it'd add too much clutter to the output, feel free to close the PR.

@3lpsy 3lpsy requested a review from a team as a code owner January 18, 2025 17:39
@github-actions
Copy link
Contributor

github-actions bot commented Jan 18, 2025

Package Changes Through 146ab48

There are 2 changes which include tauri-cli with patch, @tauri-apps/cli with patch

Planned Package Versions

The following package releases are the planned based on the context of changes in this pull request.

package current next
@tauri-apps/cli 2.2.5 2.2.6
tauri-cli 2.2.5 2.2.6

Add another change file through the GitHub UI by following this link.


Read about change files or the docs at github.com/jbolda/covector

amrbashir
amrbashir previously approved these changes Jan 18, 2025
Copy link
Member

@amrbashir amrbashir left a comment

Choose a reason for hiding this comment

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

Thank you, this is awesome

amrbashir
amrbashir previously approved these changes Jan 18, 2025
@amrbashir amrbashir merged commit 0b79af7 into tauri-apps:dev Jan 18, 2025
14 checks passed
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