Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

VSCode tasks add fbt format and clear commands#4302

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
xMasterX wants to merge1 commit intoflipperdevices:dev
base:dev
Choose a base branch
Loading
fromxMasterX:vscode_easy_tasks

Conversation

@xMasterX
Copy link
Contributor

What's new

  • Add fbt format and fbt clear to command list

Verification

  • fbt vscode_dist and press f1 and select tasks

Checklist (For Reviewer)

  • PR has description of feature/bug or link to Confluence/Jira task
  • Description contains actions to verify feature/bugfix
  • I've built this code, uploaded it to the device and verified feature/bugfix

@sowavy234
Copy link

Review: Issues Found in tasks.json Configuration

I've reviewed the added VSCode tasks and identified several errors that need to be corrected:

Issues Identified:

  1. Incorrectgroup syntax - The group property should be an object{"kind": "build"}, not a string"build"
  2. Missing Windows compatibility - Commands using./fbt won't work on Windows (should befbt.cmd orfbt.bat)
  3. Missing newline at end of file - JSON files should end with a newline
  4. MissingproblemMatcher - Tasks should include appropriate problem matchers for better VS Code integration

Corrected Configuration:

Here's the properly formatted version:

{"label":"[FBT] Format","group": {"kind":"build"  },"type":"shell","command":"./fbt","args": ["format"],"windows": {"command":"fbt.cmd","args": ["format"]  },"problemMatcher": []},{"label":"[FBT] Clear","group": {"kind":"build"  },"type":"shell","command":"./fbt","args": ["-c"],"windows": {"command":"fbt.cmd","args": ["-c"]  },"problemMatcher": []},

Key Changes Explained:

  • group object format: VS Code's task schema requiresgroup to be an object with akind property for proper task categorization
  • args array: Separated command and arguments for better cross-platform compatibility and proper shell escaping
  • windows property: Provides Windows-specific command (fbt.cmd) ensuring the tasks work on both Unix and Windows environments
  • problemMatcher: Added empty array to suppress VS Code warnings (can be enhanced with custom matchers if needed)
  • File ending: Ensure the file ends with a newline character

These changes ensure the tasks work correctly across all platforms and follow VS Code's task configuration best practices.

@xMasterX
Copy link
ContributorAuthor

Review: Issues Found in tasks.json Configuration

I've reviewed the added VSCode tasks and identified several errors that need to be corrected:

Issues Identified:

  1. Incorrectgroup syntax - The group property should be an object{"kind": "build"}, not a string"build"
  2. Missing Windows compatibility - Commands using./fbt won't work on Windows (should befbt.cmd orfbt.bat)
  3. Missing newline at end of file - JSON files should end with a newline
  4. MissingproblemMatcher - Tasks should include appropriate problem matchers for better VS Code integration

Corrected Configuration:

Here's the properly formatted version:

{"label":"[FBT] Format","group": {"kind":"build"  },"type":"shell","command":"./fbt","args": ["format"],"windows": {"command":"fbt.cmd","args": ["format"]  },"problemMatcher": []},{"label":"[FBT] Clear","group": {"kind":"build"  },"type":"shell","command":"./fbt","args": ["-c"],"windows": {"command":"fbt.cmd","args": ["-c"]  },"problemMatcher": []},

Key Changes Explained:

  • group object format: VS Code's task schema requiresgroup to be an object with akind property for proper task categorization
  • args array: Separated command and arguments for better cross-platform compatibility and proper shell escaping
  • windows property: Provides Windows-specific command (fbt.cmd) ensuring the tasks work on both Unix and Windows environments
  • problemMatcher: Added empty array to suppress VS Code warnings (can be enhanced with custom matchers if needed)
  • File ending: Ensure the file ends with a newline character

These changes ensure the tasks work correctly across all platforms and follow VS Code's task configuration best practices.

Wow, AI reviewing my simplest PR, cool

WillyJL reacted with laugh emoji

@hedgerhedger added Build System & Scriptsfbt, scripts and toolchain-related New FeatureContains an IMPLEMENTATION of a new feature labelsNov 6, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@DrZlo13DrZlo13Awaiting requested review from DrZlo13DrZlo13 is a code owner

@hedgerhedgerAwaiting requested review from hedgerhedger is a code owner

@gsurkovgsurkovAwaiting requested review from gsurkovgsurkov is a code owner

At least 1 approving review is required to merge this pull request.

Assignees

No one assigned

Labels

Build System & Scriptsfbt, scripts and toolchain-relatedNew FeatureContains an IMPLEMENTATION of a new feature

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants

@xMasterX@sowavy234@hedger

[8]ページ先頭

©2009-2025 Movatter.jp