Skip to content

Comments

chore: Vscode support#106

Draft
demm05 wants to merge 1 commit intomainfrom
chore/vscode-support
Draft

chore: Vscode support#106
demm05 wants to merge 1 commit intomainfrom
chore/vscode-support

Conversation

@demm05
Copy link
Member

@demm05 demm05 commented Dec 24, 2025

No description provided.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds Visual Studio Code IDE support to the project by including VSCode configuration files for tasks, debugging, editor settings, and C++ IntelliSense. The .vscode/ directory is removed from .gitignore to allow these configurations to be tracked in version control.

  • Added VSCode task definitions for common Makefile targets (all, clean, fclean, re, build_tests)
  • Added debug launch configurations for webserv and run_tests with LLDB debugger
  • Updated C++ IntelliSense configuration with project-specific include paths and defines
  • Configured editor settings for consistent formatting with tabs and C++ file associations

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
.vscode/tasks.json Defines VSCode tasks for building and cleaning the project using make commands
.vscode/settings.json Configures editor behavior with tab settings, format-on-save, and C++ file associations
.vscode/launch.json Sets up debug configurations for webserv and run_tests executables using LLDB
.vscode/c_cpp_properties.json Updates include paths, defines LOGLEVEL, and switches to gcc-based IntelliSense
.gitignore Removes .vscode/ and .idea/ from ignore list to track IDE configurations

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

"configurations": [
{
"name": "Debug webserv (config/example.conf)",
"type": "lldb",
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

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

The debugger type is hardcoded to "lldb", which is primarily available on macOS and may not be available on all Linux systems. Many Linux developers use "gdb" instead. Consider either: (1) creating separate debug configurations for different platforms, or (2) using "cppdbg" type which works with both gdb and lldb, or (3) documenting that the LLDB VSCode extension needs to be installed.

Copilot uses AI. Check for mistakes.
Comment on lines +6 to +38
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [
"config/example.conf"
],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug webserv (no args)",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug run_tests",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/run_tests",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make build_tests"
},
{
"name": "Attach to webserv",
"type": "lldb",
"request": "attach",
"program": "${workspaceFolder}/webserv",
"processId": "${command:pickProcess}"
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

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

The debugger type is hardcoded to "lldb", which is primarily available on macOS and may not be available on all Linux systems. Many Linux developers use "gdb" instead. Consider either: (1) creating separate debug configurations for different platforms, or (2) using "cppdbg" type which works with both gdb and lldb, or (3) documenting that the LLDB VSCode extension needs to be installed.

Suggested change
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [
"config/example.conf"
],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug webserv (no args)",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug run_tests",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/run_tests",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make build_tests"
},
{
"name": "Attach to webserv",
"type": "lldb",
"request": "attach",
"program": "${workspaceFolder}/webserv",
"processId": "${command:pickProcess}"
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [
"config/example.conf"
],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all",
"MIMode": "gdb",
"miDebuggerPath": "gdb"
},
{
"name": "Debug webserv (no args)",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all",
"MIMode": "gdb",
"miDebuggerPath": "gdb"
},
{
"name": "Debug run_tests",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/run_tests",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make build_tests",
"MIMode": "gdb",
"miDebuggerPath": "gdb"
},
{
"name": "Attach to webserv",
"type": "cppdbg",
"request": "attach",
"program": "${workspaceFolder}/webserv",
"processId": "${command:pickProcess}",
"MIMode": "gdb",
"miDebuggerPath": "gdb"

Copilot uses AI. Check for mistakes.
Comment on lines +6 to +38
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [
"config/example.conf"
],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug webserv (no args)",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug run_tests",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/run_tests",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make build_tests"
},
{
"name": "Attach to webserv",
"type": "lldb",
"request": "attach",
"program": "${workspaceFolder}/webserv",
"processId": "${command:pickProcess}"
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

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

The debugger type is hardcoded to "lldb", which is primarily available on macOS and may not be available on all Linux systems. Many Linux developers use "gdb" instead. Consider either: (1) creating separate debug configurations for different platforms, or (2) using "cppdbg" type which works with both gdb and lldb, or (3) documenting that the LLDB VSCode extension needs to be installed.

Suggested change
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [
"config/example.conf"
],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug webserv (no args)",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all"
},
{
"name": "Debug run_tests",
"type": "lldb",
"request": "launch",
"program": "${workspaceFolder}/run_tests",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make build_tests"
},
{
"name": "Attach to webserv",
"type": "lldb",
"request": "attach",
"program": "${workspaceFolder}/webserv",
"processId": "${command:pickProcess}"
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [
"config/example.conf"
],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all",
"MIMode": "gdb"
},
{
"name": "Debug webserv (no args)",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/webserv",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make all",
"MIMode": "gdb"
},
{
"name": "Debug run_tests",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/run_tests",
"args": [],
"cwd": "${workspaceFolder}",
"preLaunchTask": "make build_tests",
"MIMode": "gdb"
},
{
"name": "Attach to webserv",
"type": "cppdbg",
"request": "attach",
"program": "${workspaceFolder}/webserv",
"processId": "${command:pickProcess}",
"MIMode": "gdb"

Copilot uses AI. Check for mistakes.
Comment on lines +15 to +16
"intelliSenseMode": "linux-gcc-x64",
"compilerPath": "/usr/bin/c++"
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

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

The configuration is named "Linux / macOS" but uses "linux-gcc-x64" for intelliSenseMode and "/usr/bin/c++" for compilerPath, which are Linux-specific paths. On macOS, the typical compiler path would be different (often using clang). Consider either: (1) creating separate configurations for Linux and macOS, or (2) using more portable settings, or (3) renaming to indicate this is Linux-specific.

Copilot uses AI. Check for mistakes.
@demm05 demm05 marked this pull request as draft January 13, 2026 19:16
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